bug 215121 - Externalize Strings. Updated plugins so that they externalized the strings that are displayed in the logs and ui.
diff --git a/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/AbstractTableBlock.java b/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/AbstractTableBlock.java
index 51215e9..e121c88 100644
--- a/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/AbstractTableBlock.java
+++ b/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/AbstractTableBlock.java
@@ -38,9 +38,9 @@
int columnCount = getTable().getColumnCount();
for (int i = 0; i < columnCount; i++)
{
- getDialogSettings().put(getQualifier() + ".columnWidth" + i, getTable().getColumn(i).getWidth());
+ getDialogSettings().put(getQualifier() + ".columnWidth" + i, getTable().getColumn(i).getWidth()); //$NON-NLS-1$
}
- getDialogSettings().put(getQualifier() + ".sortColumn", fSortColumn);
+ getDialogSettings().put(getQualifier() + ".sortColumn", fSortColumn); //$NON-NLS-1$
}
/**
@@ -55,7 +55,7 @@
int col = 0;
try
{
- col = getDialogSettings().getInt(getQualifier() + ".sortColumn");
+ col = getDialogSettings().getInt(getQualifier() + ".sortColumn"); //$NON-NLS-1$
}
catch (NumberFormatException e)
{
@@ -72,7 +72,7 @@
int width = -1;
try
{
- width = settings.getInt(qualifier + ".columnWidth" + i);
+ width = settings.getInt(qualifier + ".columnWidth" + i); //$NON-NLS-1$
}
catch (NumberFormatException e)
{
diff --git a/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/Messages.java b/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/Messages.java
new file mode 100644
index 0000000..f543dc8
--- /dev/null
+++ b/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/Messages.java
@@ -0,0 +1,22 @@
+package org.eclipse.wst.xsl.internal.debug.ui;
+
+import java.util.MissingResourceException;
+import java.util.ResourceBundle;
+
+public class Messages {
+ private static final String BUNDLE_NAME = "org.eclipse.wst.xsl.internal.debug.ui.messages"; //$NON-NLS-1$
+
+ private static final ResourceBundle RESOURCE_BUNDLE = ResourceBundle
+ .getBundle(BUNDLE_NAME);
+
+ private Messages() {
+ }
+
+ public static String getString(String key) {
+ try {
+ return RESOURCE_BUNDLE.getString(key);
+ } catch (MissingResourceException e) {
+ return '!' + key + '!';
+ }
+ }
+}
diff --git a/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/ResourceSelectionBlock.java b/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/ResourceSelectionBlock.java
index 07d855e..a108cc2 100644
--- a/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/ResourceSelectionBlock.java
+++ b/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/ResourceSelectionBlock.java
@@ -78,7 +78,7 @@
protected boolean required;
protected String defaultOutputFile;
protected String outputFile;
- protected String fileLabel = "File:";
+ protected String fileLabel = Messages.getString("ResourceSelectionBlock.0"); //$NON-NLS-1$
private final ISelectionStatusValidator validator = new ISelectionStatusValidator()
{
@@ -86,16 +86,16 @@
{
if (selection.length == 0)
{
- return new Status(IStatus.ERROR, XSLDebugUIPlugin.PLUGIN_ID, 0, "", null);
+ return new Status(IStatus.ERROR, XSLDebugUIPlugin.PLUGIN_ID, 0, "", null); //$NON-NLS-1$
}
for (int i = 0; i < selection.length; i++)
{
if (resourceType == IResource.FOLDER && !(selection[i] instanceof IFolder))
- return new Status(IStatus.ERROR, XSLDebugUIPlugin.PLUGIN_ID, 0, "", null);
+ return new Status(IStatus.ERROR, XSLDebugUIPlugin.PLUGIN_ID, 0, "", null); //$NON-NLS-1$
else if (resourceType == IResource.FILE && !(selection[i] instanceof IFile))
- return new Status(IStatus.ERROR, XSLDebugUIPlugin.PLUGIN_ID, 0, "", null);
+ return new Status(IStatus.ERROR, XSLDebugUIPlugin.PLUGIN_ID, 0, "", null); //$NON-NLS-1$
}
- return new Status(IStatus.OK, XSLDebugUIPlugin.PLUGIN_ID, 0, "", null);
+ return new Status(IStatus.OK, XSLDebugUIPlugin.PLUGIN_ID, 0, "", null); //$NON-NLS-1$
}
};
@@ -254,11 +254,11 @@
{
if (useDefault)
{
- resourceText.setText(defaultOutputFile == null ? "" : defaultOutputFile);
+ resourceText.setText(defaultOutputFile == null ? "" : defaultOutputFile); //$NON-NLS-1$
}
else
{
- resourceText.setText(outputFile == null ? "" : outputFile);
+ resourceText.setText(outputFile == null ? "" : outputFile); //$NON-NLS-1$
}
resourceText.setEnabled(!useDefault);
fFileSystemButton.setEnabled(!useDefault);
@@ -279,7 +279,7 @@
{
DirectoryDialog dialog = new DirectoryDialog(getShell());
dialog.setMessage(getMessage(DIRECTORY_DIALOG_MESSAGE));
- if (!currentWorkingDir.trim().equals(""))
+ if (!currentWorkingDir.trim().equals("")) //$NON-NLS-1$
{
File path = new File(currentWorkingDir);
if (path.exists())
@@ -292,7 +292,7 @@
else
{
FileDialog dialog = new FileDialog(getShell());
- if (!currentWorkingDir.trim().equals(""))
+ if (!currentWorkingDir.trim().equals("")) //$NON-NLS-1$
{
File path = new File(currentWorkingDir);
if (path.exists())
@@ -307,7 +307,7 @@
for (int i = 0; i < fileExtensions.length; i++)
{
String ext = fileExtensions[i];
- filterExtensions[i] = "*." + ext;
+ filterExtensions[i] = "*." + ext; //$NON-NLS-1$
}
dialog.setFilterExtensions(filterExtensions);
}
@@ -328,7 +328,7 @@
{
IPath path = openWorkspaceResourceDialog();
if (path != null)
- setText("${workspace_loc:" + path.toString() + "}");
+ setText("${workspace_loc:" + path.toString() + "}"); //$NON-NLS-1$ //$NON-NLS-2$
}
protected IPath openWorkspaceResourceDialog()
@@ -395,7 +395,7 @@
{
IResource res = null;
IWorkspaceRoot root = ResourcesPlugin.getWorkspace().getRoot();
- if (path.startsWith("${workspace_loc:"))
+ if (path.startsWith("${workspace_loc:")) //$NON-NLS-1$
{
IStringVariableManager manager = VariablesPlugin.getDefault().getStringVariableManager();
try
@@ -451,7 +451,7 @@
setMessage(null);
// if variables are present, we cannot resolve the directory
String workingDirPath = getText();
- if (workingDirPath.indexOf("${") >= 0)
+ if (workingDirPath.indexOf("${") >= 0) //$NON-NLS-1$
{
IStringVariableManager manager = VariablesPlugin.getDefault().getStringVariableManager();
try
diff --git a/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/XSLConsoleLineTracker.java b/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/XSLConsoleLineTracker.java
index ec70794..012d7ec 100644
--- a/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/XSLConsoleLineTracker.java
+++ b/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/XSLConsoleLineTracker.java
@@ -63,7 +63,7 @@
try
{
String launchTypeId = console.getProcess().getLaunch().getLaunchConfiguration().getType().getIdentifier();
- this.enabled = "org.eclipse.wst.xsl.launching.launchConfigurationType".equals(launchTypeId);
+ this.enabled = "org.eclipse.wst.xsl.launching.launchConfigurationType".equals(launchTypeId); //$NON-NLS-1$
}
catch (CoreException e)
{
@@ -155,7 +155,7 @@
{
return;
}
- if ("file".equals(url.getProtocol()))
+ if ("file".equals(url.getProtocol())) //$NON-NLS-1$
{
String path = URLDecoder.decode(url.getPath());
Path fExternalPath = new Path(path);
diff --git a/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/XSLDebugUIConstants.java b/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/XSLDebugUIConstants.java
index 0d314a2..823641d 100644
--- a/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/XSLDebugUIConstants.java
+++ b/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/XSLDebugUIConstants.java
@@ -14,13 +14,13 @@
public class XSLDebugUIConstants
{
private static final String PREFIX = XSLDebugUIPlugin.PLUGIN_ID + '.';
- public static final String PROCESSOR_DETAILS_DIALOG = PREFIX + "PROCESSOR_DETAILS_DIALOG";
- public static final String PROCESSOR_OUTPUT_PROPERTIES_BLOCK = PREFIX + "PROCESSOR_OUTPUT_PROPERTIES_BLOCK";
- public static final String MAIN_PARAMATERS_BLOCK = PREFIX + "MAIN_PARAMATERS_BLOCK";
- public static final String MAIN_TRANSFORMS_BLOCK = PREFIX + "MAIN_TRANSFORMS_BLOCK";
- public static final String FEATURES_BLOCK = PREFIX + "FEATURES_BLOCK";
- public static final String OUTPUT_BLOCK = PREFIX + "OUTPUT_BLOCK";
- public static final String FEATURES_LAUNCH_BLOCK = PREFIX + "FEATURES_LAUNCH_BLOCK";
+ public static final String PROCESSOR_DETAILS_DIALOG = PREFIX + "PROCESSOR_DETAILS_DIALOG"; //$NON-NLS-1$
+ public static final String PROCESSOR_OUTPUT_PROPERTIES_BLOCK = PREFIX + "PROCESSOR_OUTPUT_PROPERTIES_BLOCK"; //$NON-NLS-1$
+ public static final String MAIN_PARAMATERS_BLOCK = PREFIX + "MAIN_PARAMATERS_BLOCK"; //$NON-NLS-1$
+ public static final String MAIN_TRANSFORMS_BLOCK = PREFIX + "MAIN_TRANSFORMS_BLOCK"; //$NON-NLS-1$
+ public static final String FEATURES_BLOCK = PREFIX + "FEATURES_BLOCK"; //$NON-NLS-1$
+ public static final String OUTPUT_BLOCK = PREFIX + "OUTPUT_BLOCK"; //$NON-NLS-1$
+ public static final String FEATURES_LAUNCH_BLOCK = PREFIX + "FEATURES_LAUNCH_BLOCK"; //$NON-NLS-1$
- public static final String XSL_EDITOR_ID = "org.eclipse.wst.xml.ui.internal.tabletree.XMLMultiPageEditorPart";
+ public static final String XSL_EDITOR_ID = "org.eclipse.wst.xml.ui.internal.tabletree.XMLMultiPageEditorPart"; //$NON-NLS-1$
}
diff --git a/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/XSLDebugUIPlugin.java b/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/XSLDebugUIPlugin.java
index 57d8bd4..c25f3ce 100644
--- a/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/XSLDebugUIPlugin.java
+++ b/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/XSLDebugUIPlugin.java
@@ -25,7 +25,7 @@
{
// The plug-in ID
- public static final String PLUGIN_ID = "org.eclipse.wst.xsl.debug.ui";
+ public static final String PLUGIN_ID = "org.eclipse.wst.xsl.debug.ui"; //$NON-NLS-1$
// The shared instance
private static XSLDebugUIPlugin plugin;
@@ -114,7 +114,7 @@
public static void log(Exception e)
{
- getDefault().getLog().log(new Status(IStatus.ERROR, PLUGIN_ID, 0, "", e));
+ getDefault().getLog().log(new Status(IStatus.ERROR, PLUGIN_ID, 0, "", e)); //$NON-NLS-1$
}
public static void log(CoreException e)
diff --git a/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/XSLLaunchShortcut.java b/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/XSLLaunchShortcut.java
index 67fcf97..76f4c7f 100644
--- a/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/XSLLaunchShortcut.java
+++ b/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/XSLLaunchShortcut.java
@@ -146,7 +146,7 @@
gd.verticalIndent = 5;
gd.widthHint = 380;
label.setLayoutData(gd);
- label.setText("Select an input file for the transformation");
+ label.setText(Messages.getString("XSLLaunchShortcut.0")); //$NON-NLS-1$
inputFileBlock.createControl(comp);
return comp;
@@ -166,7 +166,7 @@
};
dialog.setHelpAvailable(false);
dialog.setStatusLineAboveButtons(true);
- dialog.setTitle("Input File");
+ dialog.setTitle(Messages.getString("XSLLaunchShortcut.1")); //$NON-NLS-1$
dialog.open();
}
@@ -275,8 +275,8 @@
IDebugModelPresentation labelProvider = DebugUITools.newDebugModelPresentation();
ElementListSelectionDialog dialog = new ElementListSelectionDialog(getShell(), labelProvider);
dialog.setElements(configList.toArray());
- dialog.setTitle("Select a Launch Configuration");
- dialog.setMessage("&Select existing configuration:");
+ dialog.setTitle(Messages.getString("XSLLaunchShortcut.2")); //$NON-NLS-1$
+ dialog.setMessage("&Select existing configuration:"); //$NON-NLS-1$
dialog.setMultipleSelection(false);
int result = dialog.open();
labelProvider.dispose();
@@ -295,7 +295,7 @@
ILaunchConfigurationType configType = getConfigurationType();
ILaunchConfigurationWorkingCopy wc = configType.newInstance(null, getLaunchManager().generateUniqueLaunchConfigurationNameFrom(xmlFilePath.lastSegment()));
if (xmlFile != null)
- wc.setAttribute(XSLLaunchConfigurationConstants.ATTR_INPUT_FILE, "${workspace_loc:" + xmlFile.getFullPath().toPortableString()+"}");
+ wc.setAttribute(XSLLaunchConfigurationConstants.ATTR_INPUT_FILE, "${workspace_loc:" + xmlFile.getFullPath().toPortableString()+"}"); //$NON-NLS-1$ //$NON-NLS-2$
else
wc.setAttribute(XSLLaunchConfigurationConstants.ATTR_INPUT_FILE, xmlFilePath.toPortableString());
wc.setAttribute(XSLLaunchConfigurationConstants.ATTR_USE_FEATURES_FROM_PREFERENCES, true);
@@ -315,7 +315,7 @@
}
catch (CoreException exception)
{
- MessageDialog.openError(getShell(), "Error", exception.getStatus().getMessage());
+ MessageDialog.openError(getShell(), Messages.getString("XSLLaunchShortcut.6"), exception.getStatus().getMessage()); //$NON-NLS-1$
}
return config;
}
diff --git a/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/actions/ActionMessages.java b/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/actions/ActionMessages.java
index d9c102f..6a2ea22 100644
--- a/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/actions/ActionMessages.java
+++ b/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/actions/ActionMessages.java
@@ -14,7 +14,7 @@
public final class ActionMessages extends NLS
{
- private static final String BUNDLE_NAME = "org.eclipse.wst.xsl.internal.debug.ui.actions.ActionMessages";
+ private static final String BUNDLE_NAME = "org.eclipse.wst.xsl.internal.debug.ui.actions.ActionMessages"; //$NON-NLS-1$
public static String RemoveAction_Text;
diff --git a/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/actions/AddExternalFileAction.java b/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/actions/AddExternalFileAction.java
index b03f331..0c99add 100644
--- a/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/actions/AddExternalFileAction.java
+++ b/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/actions/AddExternalFileAction.java
@@ -31,12 +31,12 @@
String lastUsedPath = getDialogSetting(LAST_PATH_SETTING);
if (lastUsedPath == null)
{
- lastUsedPath = "";
+ lastUsedPath = ""; //$NON-NLS-1$
}
FileDialog dialog = new FileDialog(getShell(), SWT.MULTI);
dialog.setText(ActionMessages.AddExternalFileAction_Selection_3);
dialog.setFilterPath(lastUsedPath);
- dialog.setFilterExtensions(new String[]{ "*.xsl" });
+ dialog.setFilterExtensions(new String[]{ "*.xsl" }); //$NON-NLS-1$
String res = dialog.open();
if (res == null)
{
diff --git a/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/actions/AddParameterAction.java b/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/actions/AddParameterAction.java
index c512922..163087d 100644
--- a/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/actions/AddParameterAction.java
+++ b/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/actions/AddParameterAction.java
@@ -43,7 +43,7 @@
int type = dialog.getIntValue(typelabel);
String value = dialog.getStringValue(variableslabel);
LaunchAttribute parameter = null;
- if (value != null && value.indexOf("${") > -1)
+ if (value != null && value.indexOf("${") > -1) //$NON-NLS-1$
parameter = new LaunchAttribute(name, types[type], value);
else
parameter = new LaunchAttribute(name, types[type], value);
diff --git a/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/actions/AddWorkspaceFileAction.java b/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/actions/AddWorkspaceFileAction.java
index b0eceb6..a393316 100644
--- a/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/actions/AddWorkspaceFileAction.java
+++ b/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/actions/AddWorkspaceFileAction.java
@@ -38,16 +38,16 @@
{
if (selection.length == 0)
{
- return new Status(IStatus.ERROR, XSLDebugUIPlugin.PLUGIN_ID, 0, "", null);
+ return new Status(IStatus.ERROR, XSLDebugUIPlugin.PLUGIN_ID, 0, "", null); //$NON-NLS-1$
}
for (int i = 0; i < selection.length; i++)
{
if (!(selection[i] instanceof IFile))
{
- return new Status(IStatus.ERROR, XSLDebugUIPlugin.PLUGIN_ID, 0, "", null);
+ return new Status(IStatus.ERROR, XSLDebugUIPlugin.PLUGIN_ID, 0, "", null); //$NON-NLS-1$
}
}
- return new Status(IStatus.OK, XSLDebugUIPlugin.PLUGIN_ID, 0, "", null);
+ return new Status(IStatus.OK, XSLDebugUIPlugin.PLUGIN_ID, 0, "", null); //$NON-NLS-1$
}
};
@@ -78,7 +78,7 @@
return true;
IFile file = (IFile) element;
String fileExt = file.getFileExtension();
- if (fileExt != null && fileExt.equalsIgnoreCase("xsl"))
+ if (fileExt != null && fileExt.equalsIgnoreCase("xsl")) //$NON-NLS-1$
{
return true;
}
diff --git a/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/actions/ControlAccessibleListener.java b/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/actions/ControlAccessibleListener.java
index 881819f..423ff7f 100644
--- a/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/actions/ControlAccessibleListener.java
+++ b/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/actions/ControlAccessibleListener.java
@@ -32,7 +32,7 @@
public static void addListener(Control comp, String name)
{
// strip mnemonic
- String[] strs = name.split("&");
+ String[] strs = name.split("&"); //$NON-NLS-1$
StringBuffer stripped = new StringBuffer();
for (String element : strs)
{
diff --git a/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/actions/MultipleInputDialog.java b/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/actions/MultipleInputDialog.java
index a90e55c..f2df4bb 100644
--- a/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/actions/MultipleInputDialog.java
+++ b/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/actions/MultipleInputDialog.java
@@ -39,7 +39,7 @@
public class MultipleInputDialog extends Dialog
{
- protected static final String FIELD_NAME = "FIELD_NAME";
+ protected static final String FIELD_NAME = "FIELD_NAME"; //$NON-NLS-1$
protected static final int TEXT = 100;
protected static final int BROWSE = 101;
protected static final int VARIABLE = 102;
@@ -170,7 +170,7 @@
@Override
public boolean validate()
{
- return !text.getText().equals("");
+ return !text.getText().equals(""); //$NON-NLS-1$
}
});
text.addModifyListener(new ModifyListener()
@@ -219,7 +219,7 @@
@Override
public boolean validate()
{
- return !text.getText().equals("");
+ return !text.getText().equals(""); //$NON-NLS-1$
}
});
@@ -342,7 +342,7 @@
private String getDialogSettingsSectionName()
{
- return XSLDebugUIPlugin.PLUGIN_ID + ".MULTIPLE_INPUT_DIALOG";
+ return XSLDebugUIPlugin.PLUGIN_ID + ".MULTIPLE_INPUT_DIALOG"; //$NON-NLS-1$
}
@Override
diff --git a/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/actions/OpenDialogAction.java b/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/actions/OpenDialogAction.java
index 723c1fa..b8de6ee 100644
--- a/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/actions/OpenDialogAction.java
+++ b/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/actions/OpenDialogAction.java
@@ -16,7 +16,7 @@
public class OpenDialogAction extends AbstractStylesheetAction
{
- protected static final String LAST_PATH_SETTING = "LAST_PATH_SETTING";
+ protected static final String LAST_PATH_SETTING = "LAST_PATH_SETTING"; //$NON-NLS-1$
private String fPrefix = null;
public OpenDialogAction(String label, StylesheetViewer viewer, String dialogSettingsPrefix)
@@ -32,12 +32,12 @@
protected String getDialogSetting(String settingName)
{
- return getDialogSettings().get(getDialogSettingsPrefix() + "." + settingName);
+ return getDialogSettings().get(getDialogSettingsPrefix() + "." + settingName); //$NON-NLS-1$
}
protected void setDialogSetting(String settingName, String value)
{
- getDialogSettings().put(getDialogSettingsPrefix() + "." + settingName, value);
+ getDialogSettings().put(getDialogSettingsPrefix() + "." + settingName, value); //$NON-NLS-1$
}
protected IDialogSettings getDialogSettings()
diff --git a/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/breakpoint/Messages.java b/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/breakpoint/Messages.java
new file mode 100644
index 0000000..49c7404
--- /dev/null
+++ b/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/breakpoint/Messages.java
@@ -0,0 +1,15 @@
+package org.eclipse.wst.xsl.internal.debug.ui.breakpoint;
+
+import org.eclipse.osgi.util.NLS;
+
+public class Messages extends NLS {
+ private static final String BUNDLE_NAME = "org.eclipse.wst.xsl.internal.debug.ui.breakpoint.messages"; //$NON-NLS-1$
+ public static String XSLBreakpointProvider_0;
+ static {
+ // initialize resource bundle
+ NLS.initializeMessages(BUNDLE_NAME, Messages.class);
+ }
+
+ private Messages() {
+ }
+}
diff --git a/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/breakpoint/XSLBreakpointProvider.java b/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/breakpoint/XSLBreakpointProvider.java
index dcd2de8..8bab02b 100644
--- a/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/breakpoint/XSLBreakpointProvider.java
+++ b/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/breakpoint/XSLBreakpointProvider.java
@@ -52,7 +52,7 @@
IBreakpoint point = new XSLLineBreakpoint(res, editorLineNumber, pos, pos);
if (point == null)
{
- status = new Status(IStatus.ERROR, XSLDebugUIPlugin.PLUGIN_ID, IStatus.ERROR, "unsupported input type", null);
+ status = new Status(IStatus.ERROR, XSLDebugUIPlugin.PLUGIN_ID, IStatus.ERROR, Messages.XSLBreakpointProvider_0, null);
}
else
{
@@ -73,13 +73,13 @@
IBreakpoint point = new XSLLineBreakpoint(res, editorLineNumber, pos, pos);
if (point == null)
{
- status = new Status(IStatus.ERROR, XSLDebugUIPlugin.PLUGIN_ID, IStatus.ERROR, "unsupported input type", null);
+ status = new Status(IStatus.ERROR, XSLDebugUIPlugin.PLUGIN_ID, IStatus.ERROR, Messages.XSLBreakpointProvider_0, null);
}
}
}
if (status == null)
{
- status = new Status(IStatus.OK, XSLDebugUIPlugin.PLUGIN_ID, IStatus.OK, "JSPUIMessages.OK", null);
+ status = new Status(IStatus.OK, XSLDebugUIPlugin.PLUGIN_ID, IStatus.OK, "JSPUIMessages.OK", null); //$NON-NLS-1$
}
return status;
}
@@ -115,7 +115,7 @@
String lineText = idoc.get(startOffset, endOffset - startOffset).trim();
// blank lines or PI's cannot have breakpoints
- if (lineText.trim().equals("") || lineText.startsWith("<?"))
+ if (lineText.trim().equals("") || lineText.startsWith("<?")) //$NON-NLS-1$ //$NON-NLS-2$
{
result = -1;
}
diff --git a/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/breakpoint/messages.properties b/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/breakpoint/messages.properties
new file mode 100644
index 0000000..30115d4
--- /dev/null
+++ b/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/breakpoint/messages.properties
@@ -0,0 +1 @@
+XSLBreakpointProvider_0=unsupported input type
diff --git a/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/messages.properties b/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/messages.properties
new file mode 100644
index 0000000..d51967d
--- /dev/null
+++ b/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/messages.properties
@@ -0,0 +1,5 @@
+ResourceSelectionBlock.0=File:
+XSLLaunchShortcut.0=Select an input file for the transformation
+XSLLaunchShortcut.1=Input File
+XSLLaunchShortcut.2=Select a Launch Configuration
+XSLLaunchShortcut.6=Error
diff --git a/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/model/XSLBreakpointAdapterFactory.java b/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/model/XSLBreakpointAdapterFactory.java
index c1916ad..ceb09a3 100644
--- a/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/model/XSLBreakpointAdapterFactory.java
+++ b/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/model/XSLBreakpointAdapterFactory.java
@@ -20,7 +20,7 @@
*/
public class XSLBreakpointAdapterFactory implements IAdapterFactory
{
- @SuppressWarnings("unchecked")
+ @SuppressWarnings("unchecked") //$NON-NLS-1$
public Object getAdapter(Object adaptableObject, Class adapterType)
{
if (adaptableObject instanceof ITextEditor)
@@ -30,7 +30,7 @@
if (resource != null)
{
String extension = resource.getFileExtension();
- if (extension != null && extension.equalsIgnoreCase("xsl"))
+ if (extension != null && extension.equalsIgnoreCase("xsl")) //$NON-NLS-1$
{
return new XSLLineBreakpointAdapter();
}
@@ -39,7 +39,7 @@
return null;
}
- @SuppressWarnings("unchecked")
+ @SuppressWarnings("unchecked") //$NON-NLS-1$
public Class[] getAdapterList()
{
return new Class[]
diff --git a/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/model/XSLLineBreakpointAdapter.java b/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/model/XSLLineBreakpointAdapter.java
index c382c31..90b3340 100644
--- a/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/model/XSLLineBreakpointAdapter.java
+++ b/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/model/XSLLineBreakpointAdapter.java
@@ -71,7 +71,7 @@
{
String extension = resource.getFileExtension();
// TODO handle other file extensions/content types
- if (extension != null && extension.equalsIgnoreCase("xsl"))
+ if (extension != null && extension.equalsIgnoreCase("xsl")) //$NON-NLS-1$
{
return editorPart;
}
diff --git a/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/model/XSLModelPresentation.java b/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/model/XSLModelPresentation.java
index 57f80f1..01a1631 100644
--- a/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/model/XSLModelPresentation.java
+++ b/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/model/XSLModelPresentation.java
@@ -41,7 +41,7 @@
if (var.getScope().equals(XSLVariable.LOCAL_SCOPE))
{
if (localImg == null)
- localImg = XSLDebugUIPlugin.getImageDescriptor("/icons/localvariable_obj.gif").createImage();
+ localImg = XSLDebugUIPlugin.getImageDescriptor("/icons/localvariable_obj.gif").createImage(); //$NON-NLS-1$
return localImg;
}
}
@@ -64,7 +64,7 @@
public void computeDetail(IValue value, IValueDetailListener listener)
{
- String detail = "";
+ String detail = ""; //$NON-NLS-1$
try
{
detail = value.getValueString();
diff --git a/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/preferences/AddProcessorDialog.java b/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/preferences/AddProcessorDialog.java
index 3b0058e..2405723 100644
--- a/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/preferences/AddProcessorDialog.java
+++ b/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/preferences/AddProcessorDialog.java
@@ -77,7 +77,7 @@
if (install == null)
{
adding = true;
- standin = new InstallStandin(XSLTRuntime.createUniqueProcessorId(selectedProcessorType), "", selectedProcessorType.getId(), null, new IProcessorJar[0]);
+ standin = new InstallStandin(XSLTRuntime.createUniqueProcessorId(selectedProcessorType), "", selectedProcessorType.getId(), null, new IProcessorJar[0]); //$NON-NLS-1$
}
else
{
@@ -141,19 +141,19 @@
});
label = new Label(parent, SWT.NONE);
- label.setText("Supported versions:");
+ label.setText(ProcessorMessages.AddProcessorDialog_1);
supportsVerson10Checkbox = new Button(parent, SWT.CHECK);
gd = new GridData();
gd.horizontalSpan = 2;
supportsVerson10Checkbox.setLayoutData(gd);
- supportsVerson10Checkbox.setText("XSLT 1.0");
+ supportsVerson10Checkbox.setText("XSLT 1.0"); //$NON-NLS-1$
label = new Label(parent, SWT.NONE);
supportsVerson20Checkbox = new Button(parent, SWT.CHECK);
gd = new GridData();
gd.horizontalSpan = 2;
supportsVerson20Checkbox.setLayoutData(gd);
- supportsVerson20Checkbox.setText("XSLT 2.0");
+ supportsVerson20Checkbox.setText("XSLT 2.0"); //$NON-NLS-1$
}
protected void createFieldListeners()
@@ -265,7 +265,7 @@
processorTypeField.setInput(processorTypes);
if (adding)
{
- processorNameField.setText("");
+ processorNameField.setText(""); //$NON-NLS-1$
processorTypeField.setSelection(new StructuredSelection(processorTypes[0]));
supportsVerson10Checkbox.setSelection(true);
fLibraryBlock.initializeFrom(standinProcessor, selectedProcessorType);
@@ -276,8 +276,8 @@
processorTypeField.setSelection(new StructuredSelection(standinProcessor.getProcessorType()));
processorNameField.setText(standinProcessor.getName());
- supportsVerson10Checkbox.setSelection(standinProcessor.supports("1.0"));
- supportsVerson20Checkbox.setSelection(standinProcessor.supports("2.0"));
+ supportsVerson10Checkbox.setSelection(standinProcessor.supports("1.0")); //$NON-NLS-1$
+ supportsVerson20Checkbox.setSelection(standinProcessor.supports("2.0")); //$NON-NLS-1$
fLibraryBlock.initializeFrom(standinProcessor, selectedProcessorType);
}
setProcessorNameStatus(validateProcessorName());
@@ -317,7 +317,7 @@
{
IStatus status = Status.OK_STATUS;
if (!supportsVerson10Checkbox.getSelection() && !supportsVerson20Checkbox.getSelection())
- status = new Status(IStatus.ERROR, XSLDebugUIPlugin.PLUGIN_ID, IStatus.OK, "Processor must support at least one XSLT version", null);
+ status = new Status(IStatus.ERROR, XSLDebugUIPlugin.PLUGIN_ID, IStatus.OK, ProcessorMessages.AddProcessorDialog_7, null);
return status;
}
@@ -369,15 +369,15 @@
processor.setDebuggerId(element.getId());
}
- String supports = "";
+ String supports = ""; //$NON-NLS-1$
if (supportsVerson10Checkbox.getSelection())
{
- supports += "1.0";
+ supports += "1.0"; //$NON-NLS-1$
if (supportsVerson20Checkbox.getSelection())
- supports += ",";
+ supports += ","; //$NON-NLS-1$
}
if (supportsVerson20Checkbox.getSelection())
- supports += "2.0";
+ supports += "2.0"; //$NON-NLS-1$
processor.setSupports(supports);
fLibraryBlock.performApply(processor);
}
@@ -386,7 +386,7 @@
{
if (path == null || path.length() == 0)
{
- return new File("");
+ return new File(""); //$NON-NLS-1$
}
return new File(path).getAbsoluteFile();
}
@@ -427,7 +427,7 @@
protected String getDialogSettingsSectionName()
{
- return "ADD_PROCESSOR_DIALOG_SECTION";
+ return "ADD_PROCESSOR_DIALOG_SECTION"; //$NON-NLS-1$
}
@Override
diff --git a/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/preferences/FeaturesBlock.java b/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/preferences/FeaturesBlock.java
index e73c6c0..0c1dcdb 100644
--- a/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/preferences/FeaturesBlock.java
+++ b/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/preferences/FeaturesBlock.java
@@ -87,17 +87,17 @@
TableColumn c1 = new TableColumn(table, SWT.NONE);
c1.setWidth(150);
c1.setResizable(true);
- c1.setText("Feature");
+ c1.setText(Messages.getString("FeaturesBlock.0")); //$NON-NLS-1$
TableColumn c2 = new TableColumn(table, SWT.NONE);
c2.setWidth(100);
c2.setResizable(true);
- c2.setText("Type");
+ c2.setText(Messages.getString("FeaturesBlock.1")); //$NON-NLS-1$
TableColumn c3 = new TableColumn(table, SWT.NONE);
c3.setWidth(200);
c3.setResizable(true);
- c3.setText("Value");
+ c3.setText(Messages.getString("FeaturesBlock.2")); //$NON-NLS-1$
tViewer = new TableViewer(table);
tViewer.setContentProvider(new IStructuredContentProvider()
@@ -138,9 +138,9 @@
return feature.getType();
case 2:
String value = (String) featureValues.get(feature.getURI());
- return value == null ? "" : value;
+ return value == null ? "" : value; //$NON-NLS-1$
}
- return "!!";
+ return "!!"; //$NON-NLS-1$
}
private String removeURI(String uri)
@@ -170,27 +170,27 @@
});
tViewer.setColumnProperties(new String[]
- { "name", "type", "value" });
+ { Messages.getString("FeaturesBlock.5"), Messages.getString("FeaturesBlock.6"), Messages.getString("FeaturesBlock.7") }); //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
final String[] valid = new String[]{null};
tViewer.setCellModifier(new ICellModifier()
{
public boolean canModify(Object element, String property)
{
- return "value".equals(property);
+ return Messages.getString("FeaturesBlock.8").equals(property); //$NON-NLS-1$
}
public Object getValue(Object element, String property)
{
IFeature feature = (IFeature) element;
String value = (String) featureValues.get(feature.getURI());
- return value == null ? "" : value;
+ return value == null ? "" : value; //$NON-NLS-1$
}
public void modify(Object element, String property, Object value)
{
Item item = (Item) element;
IFeature feature = (IFeature) item.getData();
- if (value == null || "".equals(value))
+ if (value == null || "".equals(value)) //$NON-NLS-1$
featureValues.remove(feature.getURI());
else
featureValues.put(feature.getURI(), (String)value);
@@ -218,7 +218,7 @@
IStructuredSelection sel = (IStructuredSelection) tViewer.getSelection();
IFeature feature = (IFeature) sel.getFirstElement();
IStatus validStatus = feature.validateValue((String) value);
- if (value == null || "".equals(value))
+ if (value == null || "".equals(value)) //$NON-NLS-1$
valid[0] = null;
else if (validStatus != null && validStatus.getSeverity() == IStatus.ERROR)
valid[0] = validStatus.getMessage();
@@ -240,7 +240,7 @@
String text = null;
if (selection != null && selection.getFirstElement() != null)
text = ((IFeature) selection.getFirstElement()).getDescription();
- descriptionText.setText(text == null ? "" : text);
+ descriptionText.setText(text == null ? "" : text); //$NON-NLS-1$
}
});
diff --git a/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/preferences/FeaturesPreferencePage.java b/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/preferences/FeaturesPreferencePage.java
index f863e93..6281c8e 100644
--- a/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/preferences/FeaturesPreferencePage.java
+++ b/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/preferences/FeaturesPreferencePage.java
@@ -53,8 +53,8 @@
{
super();
// only used when page is shown programatically
- setTitle("Processor Features");
- setDescription("Set default values for installed processor types");
+ setTitle(Messages.getString("FeaturesPreferencePage.0")); //$NON-NLS-1$
+ setDescription(Messages.getString("FeaturesPreferencePage.1")); //$NON-NLS-1$
}
@Override
@@ -66,7 +66,7 @@
Label label = new Label(parent, SWT.NULL);
GridData gd = new GridData(SWT.NONE, SWT.CENTER, false, false);
- label.setText("Processor Type: ");
+ label.setText(Messages.getString("FeaturesPreferencePage.2")); //$NON-NLS-1$
label.setLayoutData(gd);
Combo combo = new Combo(parent, SWT.READ_ONLY | SWT.SINGLE);
diff --git a/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/preferences/InstalledProcessorsBlock.java b/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/preferences/InstalledProcessorsBlock.java
index 91dbdf9..34aae03 100644
--- a/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/preferences/InstalledProcessorsBlock.java
+++ b/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/preferences/InstalledProcessorsBlock.java
@@ -127,7 +127,7 @@
GridData data;
Label tableLabel = new Label(parent, SWT.NONE);
- tableLabel.setText("Installed Java XSLT Processors:");
+ tableLabel.setText(ProcessorMessages.InstalledProcessorsBlock_0);
data = new GridData();
data.horizontalSpan = 2;
tableLabel.setLayoutData(data);
@@ -146,7 +146,7 @@
TableColumn column1 = new TableColumn(fTable, SWT.NONE);
column1.setWidth(150);
column1.setResizable(true);
- column1.setText("Name");
+ column1.setText(ProcessorMessages.InstalledProcessorsBlock_1);
column1.addSelectionListener(new SelectionAdapter()
{
@Override
@@ -159,7 +159,7 @@
TableColumn column2 = new TableColumn(fTable, SWT.NONE);
column2.setWidth(80);
column2.setResizable(true);
- column2.setText("Type");
+ column2.setText(ProcessorMessages.InstalledProcessorsBlock_2);
column2.addSelectionListener(new SelectionAdapter()
{
@Override
@@ -172,7 +172,7 @@
TableColumn column3 = new TableColumn(fTable, SWT.NONE);
column3.setWidth(90);
column3.setResizable(true);
- column3.setText("XSLT Versions");
+ column3.setText(ProcessorMessages.InstalledProcessorsBlock_3);
column3.addSelectionListener(new SelectionAdapter()
{
@Override
@@ -185,7 +185,7 @@
TableColumn column4 = new TableColumn(fTable, SWT.NONE);
column4.setWidth(150);
column4.setResizable(true);
- column4.setText("Debugger");
+ column4.setText(ProcessorMessages.InstalledProcessorsBlock_4);
column4.addSelectionListener(new SelectionAdapter()
{
@Override
@@ -252,7 +252,7 @@
buttons.setLayout(layout);
buttons.setFont(font);
- fAddButton = createPushButton(buttons, "Add");
+ fAddButton = createPushButton(buttons, ProcessorMessages.InstalledProcessorsBlock_5);
fAddButton.addListener(SWT.Selection, new Listener()
{
public void handleEvent(Event evt)
@@ -261,7 +261,7 @@
}
});
- fEditButton = createPushButton(buttons, "Edit");
+ fEditButton = createPushButton(buttons, ProcessorMessages.InstalledProcessorsBlock_6);
fEditButton.addListener(SWT.Selection, new Listener()
{
public void handleEvent(Event evt)
@@ -270,7 +270,7 @@
}
});
- fRemoveButton = createPushButton(buttons, "Remove");
+ fRemoveButton = createPushButton(buttons, ProcessorMessages.InstalledProcessorsBlock_7);
fRemoveButton.addListener(SWT.Selection, new Listener()
{
public void handleEvent(Event evt)
@@ -646,7 +646,7 @@
{
return install.getDebugger().getName();
}
- return "None";
+ return ProcessorMessages.InstalledProcessorsBlock_8;
}
}
return element.toString();
diff --git a/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/preferences/Messages.java b/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/preferences/Messages.java
new file mode 100644
index 0000000..32116da
--- /dev/null
+++ b/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/preferences/Messages.java
@@ -0,0 +1,22 @@
+package org.eclipse.wst.xsl.internal.debug.ui.preferences;
+
+import java.util.MissingResourceException;
+import java.util.ResourceBundle;
+
+public class Messages {
+ private static final String BUNDLE_NAME = "org.eclipse.wst.xsl.internal.debug.ui.preferences.messages"; //$NON-NLS-1$
+
+ private static final ResourceBundle RESOURCE_BUNDLE = ResourceBundle
+ .getBundle(BUNDLE_NAME);
+
+ private Messages() {
+ }
+
+ public static String getString(String key) {
+ try {
+ return RESOURCE_BUNDLE.getString(key);
+ } catch (MissingResourceException e) {
+ return '!' + key + '!';
+ }
+ }
+}
diff --git a/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/preferences/OutputBlock.java b/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/preferences/OutputBlock.java
index 499b2a3..072244d 100644
--- a/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/preferences/OutputBlock.java
+++ b/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/preferences/OutputBlock.java
@@ -72,12 +72,12 @@
TableColumn c1 = new TableColumn(table, SWT.NONE);
c1.setWidth(450);
c1.setResizable(true);
- c1.setText("Property");
+ c1.setText(Messages.getString("OutputBlock.0")); //$NON-NLS-1$
TableColumn c2 = new TableColumn(table, SWT.NONE);
c2.setWidth(150);
c2.setResizable(true);
- c2.setText("Value");
+ c2.setText(Messages.getString("OutputBlock.1")); //$NON-NLS-1$
tViewer = new TableViewer(table);
tViewer.setContentProvider(new IStructuredContentProvider()
@@ -117,7 +117,7 @@
case 1:
return (String) properties.get(prop.getURI());
}
- return "!!";
+ return "!!"; //$NON-NLS-1$
}
public void addListener(ILabelProviderListener listener)
@@ -139,26 +139,26 @@
});
tViewer.setColumnProperties(new String[]
- { "name", "value" });
+ { Messages.getString("OutputBlock.2"), Messages.getString("OutputBlock.4") }); //$NON-NLS-1$ //$NON-NLS-2$
tViewer.setCellModifier(new ICellModifier()
{
public boolean canModify(Object element, String property)
{
- return "value".equals(property);
+ return Messages.getString("OutputBlock.5").equals(property); //$NON-NLS-1$
}
public Object getValue(Object element, String property)
{
IOutputProperty prop = (IOutputProperty) element;
String value = (String) properties.get(prop.getURI());
- return value == null ? "" : value;
+ return value == null ? "" : value; //$NON-NLS-1$
}
public void modify(Object element, String property, Object value)
{
Item item = (Item) element;
IOutputProperty prop = (IOutputProperty) item.getData();
- if (value == null || "".equals(value))
+ if (value == null || "".equals(value)) //$NON-NLS-1$
properties.remove(prop.getURI());
else
properties.put(prop.getURI(), value);
diff --git a/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/preferences/OutputPreferencePage.java b/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/preferences/OutputPreferencePage.java
index 5b0ed6a..26a4866 100644
--- a/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/preferences/OutputPreferencePage.java
+++ b/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/preferences/OutputPreferencePage.java
@@ -56,8 +56,8 @@
public OutputPreferencePage()
{
super();
- setTitle("Output Properties");
- setDescription("Set output properties that will be used by default for all transformations");
+ setTitle(Messages.getString("OutputPreferencePage.0")); //$NON-NLS-1$
+ setDescription(Messages.getString("OutputPreferencePage.1")); //$NON-NLS-1$
}
@Override
@@ -68,7 +68,7 @@
parent.setLayout(layout);
Group group = new Group(parent, SWT.NONE);
- group.setText("Standard Properties");
+ group.setText(Messages.getString("OutputPreferencePage.2")); //$NON-NLS-1$
GridData gd = new GridData(SWT.FILL, SWT.FILL, true, true);
gd.heightHint = 150;
gd.widthHint = 450;
@@ -86,14 +86,14 @@
String text = null;
if (selection != null && selection.getFirstElement() != null)
text = ((IOutputProperty) selection.getFirstElement()).getDescription();
- descriptionText.setText(text == null ? "" : text);
+ descriptionText.setText(text == null ? "" : text); //$NON-NLS-1$
}
});
gd = new GridData(SWT.FILL, SWT.FILL, true, true);
standardOutputBlock.getControl().setLayoutData(gd);
group = new Group(parent, SWT.NONE);
- group.setText("Processor-Specific Properties");
+ group.setText(Messages.getString("OutputPreferencePage.4")); //$NON-NLS-1$
gd = new GridData(SWT.FILL, SWT.FILL, true, true);
gd.horizontalSpan = 2;
group.setLayoutData(gd);
@@ -101,7 +101,7 @@
Label label = new Label(group, SWT.NULL);
gd = new GridData(SWT.NONE, SWT.CENTER, false, false);
- label.setText("Processor Type:");
+ label.setText(Messages.getString("OutputPreferencePage.5")); //$NON-NLS-1$
label.setLayoutData(gd);
Combo combo = new Combo(group, SWT.READ_ONLY | SWT.SINGLE);
@@ -192,7 +192,7 @@
{
text = ((IOutputProperty) selection.getFirstElement()).getDescription();
}
- descriptionText.setText(text == null ? "" : text);
+ descriptionText.setText(text == null ? "" : text); //$NON-NLS-1$
}
});
diff --git a/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/preferences/ProcessorLibraryBlock.java b/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/preferences/ProcessorLibraryBlock.java
index 11ff0e1..1ac640c 100644
--- a/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/preferences/ProcessorLibraryBlock.java
+++ b/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/preferences/ProcessorLibraryBlock.java
@@ -59,9 +59,9 @@
public class ProcessorLibraryBlock implements SelectionListener, ISelectionChangedListener
{
- protected static final String LAST_PATH_SETTING = "LAST_PATH_SETTING";
- protected static final String LAST_WORKSPACE_PATH_SETTING = "LAST_WORKSPACE_PATH_SETTING";
- protected static final String DIALOG_SETTINGS_PREFIX = "ProcessorLibraryBlock";
+ protected static final String LAST_PATH_SETTING = "LAST_PATH_SETTING"; //$NON-NLS-1$
+ protected static final String LAST_WORKSPACE_PATH_SETTING = "LAST_WORKSPACE_PATH_SETTING"; //$NON-NLS-1$
+ protected static final String DIALOG_SETTINGS_PREFIX = "ProcessorLibraryBlock"; //$NON-NLS-1$
protected InstallStandin install;
protected IProcessorType installType;
protected AddProcessorDialog addDialog = null;
@@ -76,19 +76,19 @@
{
if (selection.length == 0)
{
- return new Status(IStatus.ERROR, XSLDebugUIPlugin.PLUGIN_ID, 0, "", null);
+ return new Status(IStatus.ERROR, XSLDebugUIPlugin.PLUGIN_ID, 0, "", null); //$NON-NLS-1$
}
for (Object element : selection)
{
if (element instanceof IFolder)
- return new Status(IStatus.ERROR, XSLDebugUIPlugin.PLUGIN_ID, 0, "", null);
+ return new Status(IStatus.ERROR, XSLDebugUIPlugin.PLUGIN_ID, 0, "", null); //$NON-NLS-1$
else if (element instanceof IFile)
{
// IFile file = (IFile) selection[i];
// TODO check that the file is not already on the classpath
}
}
- return new Status(IStatus.OK, XSLDebugUIPlugin.PLUGIN_ID, 0, "", null);
+ return new Status(IStatus.OK, XSLDebugUIPlugin.PLUGIN_ID, 0, "", null); //$NON-NLS-1$
}
};
@@ -175,7 +175,7 @@
IStatus status = Status.OK_STATUS;
if (install != null && install.getProcessorJars().length == 0)
{
- status = new Status(IStatus.INFO, XSLDebugUIPlugin.PLUGIN_ID, 0, "One or more jar files must be specified", null);
+ status = new Status(IStatus.INFO, XSLDebugUIPlugin.PLUGIN_ID, 0, ProcessorMessages.ProcessorLibraryBlock_6, null);
}
addDialog.setSystemLibraryStatus(status);
addDialog.updateStatusLine();
@@ -224,12 +224,12 @@
String lastUsedPath = dialogSettings.get(LAST_PATH_SETTING);
if (lastUsedPath == null)
{
- lastUsedPath = "";
+ lastUsedPath = ""; //$NON-NLS-1$
}
FileDialog dialog = new FileDialog(tableViewer.getControl().getShell(), SWT.MULTI);
dialog.setText(ProcessorMessages.ProcessorLibraryBlock_FileDialog_Title);
dialog.setFilterExtensions(new String[]
- { "*.jar;*.zip" });
+ { "*.jar;*.zip" }); //$NON-NLS-1$
dialog.setFilterPath(lastUsedPath);
String res = dialog.open();
if (res == null)
@@ -284,7 +284,7 @@
String extension = file.getFileExtension();
if (extension == null)
return false;
- return extension.equals("jar");
+ return extension.equals("jar"); //$NON-NLS-1$
}
return false;
}
diff --git a/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/preferences/ProcessorsPreferencePage.java b/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/preferences/ProcessorsPreferencePage.java
index ba9804f..42be424 100644
--- a/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/preferences/ProcessorsPreferencePage.java
+++ b/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/preferences/ProcessorsPreferencePage.java
@@ -36,8 +36,8 @@
{
super();
// only used when page is shown programatically
- setTitle("Java XSLT Processors");
- setDescription("Add, remove or edit XSLT processor definitions.\nBy default, the checked Processor is used for all transformations.");
+ setTitle(Messages.getString("ProcessorsPreferencePage.0")); //$NON-NLS-1$
+ setDescription(Messages.getString("ProcessorsPreferencePage.1")); //$NON-NLS-1$
}
public void init(IWorkbench workbench)
@@ -75,7 +75,7 @@
if (install == null)
{
setValid(false);
- setErrorMessage("Select a default XSLT Processor");
+ setErrorMessage(Messages.getString("ProcessorsPreferencePage.2")); //$NON-NLS-1$
}
else
{
diff --git a/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/preferences/messages.properties b/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/preferences/messages.properties
new file mode 100644
index 0000000..a2fbeca
--- /dev/null
+++ b/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/preferences/messages.properties
@@ -0,0 +1,23 @@
+FeaturesBlock.0=Feature
+FeaturesBlock.1=Type
+FeaturesBlock.2=Value
+FeaturesBlock.5=name
+FeaturesBlock.6=type
+FeaturesBlock.7=value
+FeaturesBlock.8=value
+FeaturesPreferencePage.0=Processor Features
+FeaturesPreferencePage.1=Set default values for installed processor types
+FeaturesPreferencePage.2=Processor Type:
+OutputBlock.0=Property
+OutputBlock.1=Value
+OutputBlock.2=name
+OutputBlock.4=value
+OutputBlock.5=value
+OutputPreferencePage.0=Output Properties
+OutputPreferencePage.1=Set output properties that will be used by default for all transformations
+OutputPreferencePage.2=Standard Properties
+OutputPreferencePage.4=Processor-Specific Properties
+OutputPreferencePage.5=Processor Type:
+ProcessorsPreferencePage.0=Java XSLT Processors
+ProcessorsPreferencePage.1=Add, remove or edit XSLT processor definitions.\nBy default, the checked Processor is used for all transformations.
+ProcessorsPreferencePage.2=Select a default XSLT Processor
diff --git a/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/tabs/formatter/FOFormatterTab.java b/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/tabs/formatter/FOFormatterTab.java
index 55afb25..63708cc 100644
--- a/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/tabs/formatter/FOFormatterTab.java
+++ b/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/tabs/formatter/FOFormatterTab.java
@@ -87,7 +87,7 @@
public String getName()
{
- return "Formatter";
+ return "Formatter"; //$NON-NLS-1$
}
protected void handleSelectionChanged()
diff --git a/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/tabs/formatter/Messages.java b/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/tabs/formatter/Messages.java
new file mode 100644
index 0000000..f5fc508
--- /dev/null
+++ b/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/tabs/formatter/Messages.java
@@ -0,0 +1,22 @@
+package org.eclipse.wst.xsl.internal.debug.ui.tabs.formatter;
+
+import java.util.MissingResourceException;
+import java.util.ResourceBundle;
+
+public class Messages {
+ private static final String BUNDLE_NAME = "org.eclipse.wst.xsl.internal.debug.ui.tabs.formatter.messages"; //$NON-NLS-1$
+
+ private static final ResourceBundle RESOURCE_BUNDLE = ResourceBundle
+ .getBundle(BUNDLE_NAME);
+
+ private Messages() {
+ }
+
+ public static String getString(String key) {
+ try {
+ return RESOURCE_BUNDLE.getString(key);
+ } catch (MissingResourceException e) {
+ return '!' + key + '!';
+ }
+ }
+}
diff --git a/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/tabs/formatter/RendererConfigurationBlock.java b/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/tabs/formatter/RendererConfigurationBlock.java
index a26e950..a50a1b3 100644
--- a/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/tabs/formatter/RendererConfigurationBlock.java
+++ b/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/tabs/formatter/RendererConfigurationBlock.java
@@ -18,7 +18,7 @@
{
public String getName()
{
- return "Configuration";
+ return Messages.getString("RendererConfigurationBlock.0"); //$NON-NLS-1$
}
public void initializeFrom(ILaunchConfiguration configuration)
@@ -36,7 +36,7 @@
@Override
protected String getMessage(int type)
{
- return "" + type;
+ return "" + type; //$NON-NLS-1$
}
@Override
diff --git a/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/tabs/formatter/RendererTabMessages.java b/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/tabs/formatter/RendererTabMessages.java
index a97bb1e..8622e5f 100644
--- a/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/tabs/formatter/RendererTabMessages.java
+++ b/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/tabs/formatter/RendererTabMessages.java
@@ -14,7 +14,7 @@
public final class RendererTabMessages extends NLS
{
- private static final String BUNDLE_NAME = "org.eclipse.wst.xsl.internal.debug.ui.tabs.renderer.RendererTabMessages";
+ private static final String BUNDLE_NAME = "org.eclipse.wst.xsl.internal.debug.ui.tabs.renderer.RendererTabMessages"; //$NON-NLS-1$
public static String XSLFOComboBlock_XSLFOGroupTitle;
diff --git a/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/tabs/formatter/messages.properties b/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/tabs/formatter/messages.properties
new file mode 100644
index 0000000..4b092d3
--- /dev/null
+++ b/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/tabs/formatter/messages.properties
@@ -0,0 +1 @@
+RendererConfigurationBlock.0=Configuration
diff --git a/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/tabs/main/InputFileBlock.java b/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/tabs/main/InputFileBlock.java
index 7b21e22..66eaffc 100644
--- a/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/tabs/main/InputFileBlock.java
+++ b/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/tabs/main/InputFileBlock.java
@@ -41,7 +41,7 @@
@Override
protected String[] getFileExtensions()
{
- IContentType contentType = contentTypeManager.getContentType("org.eclipse.wst.xml.core.xmlsource");
+ IContentType contentType = contentTypeManager.getContentType("org.eclipse.wst.xml.core.xmlsource"); //$NON-NLS-1$
String[] xmlContentTypes = contentType.getFileSpecs(IContentType.FILE_EXTENSION_SPEC);
return xmlContentTypes;
@@ -49,9 +49,9 @@
public void setDefaults(ILaunchConfigurationWorkingCopy configuration)
{
- String path = "";
+ String path = ""; //$NON-NLS-1$
if (defaultFile != null)
- path = VariablesPlugin.getDefault().getStringVariableManager().generateVariableExpression("workspace_loc", defaultFile.getFullPath().toPortableString());
+ path = VariablesPlugin.getDefault().getStringVariableManager().generateVariableExpression("workspace_loc", defaultFile.getFullPath().toPortableString()); //$NON-NLS-1$
configuration.setAttribute(XSLLaunchConfigurationConstants.ATTR_INPUT_FILE, path);
}
@@ -93,7 +93,7 @@
{
IPath path = null;
String workingDirPath = getText();
- if (workingDirPath.indexOf("${") >= 0)
+ if (workingDirPath.indexOf("${") >= 0) //$NON-NLS-1$
{
IStringVariableManager manager = VariablesPlugin.getDefault().getStringVariableManager();
try
@@ -139,7 +139,7 @@
case WORKSPACE_DIALOG_TITLE:
return MainTabMessages.InputFileBlock_WORKSPACE_DIALOG_TITLE;
}
- return "" + type;
+ return "" + type; //$NON-NLS-1$
}
@Override
diff --git a/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/tabs/main/MainTabMessages.java b/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/tabs/main/MainTabMessages.java
index 2299328..9ebd956 100644
--- a/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/tabs/main/MainTabMessages.java
+++ b/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/tabs/main/MainTabMessages.java
@@ -14,7 +14,7 @@
public final class MainTabMessages extends NLS
{
- private static final String BUNDLE_NAME = "org.eclipse.wst.xsl.internal.debug.ui.tabs.main.MainTabMessages";
+ private static final String BUNDLE_NAME = "org.eclipse.wst.xsl.internal.debug.ui.tabs.main.MainTabMessages"; //$NON-NLS-1$
public static String XSLMainTab_LabelText;
@@ -36,6 +36,8 @@
public static String XSLMainTab_Transforms_Group;
+ public static String TransformsBlock_0;
+
public static String TransformsBlock_Name;
public static String InputFileBlock_DIRECTORY_NOT_SPECIFIED;
@@ -70,6 +72,14 @@
public static String OutputTypeBlock_Group_Name;
+ public static String OutputFileBlock_0;
+
+ public static String OutputFileBlock_7;
+
+ public static String OutputFileBlock_8;
+
+ public static String OutputFileBlock_9;
+
public static String OutputFileBlock_DIRECTORY_NOT_SPECIFIED;
public static String OutputFileBlock_DIRECTORY_DOES_NOT_EXIST;
diff --git a/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/tabs/main/MainTabMessages.properties b/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/tabs/main/MainTabMessages.properties
index f886352..65129fe 100644
--- a/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/tabs/main/MainTabMessages.properties
+++ b/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/tabs/main/MainTabMessages.properties
@@ -9,6 +9,7 @@
XSLMainTab_Browse_Projects=Browse
XSLMainTab_TabName=Main
+TransformsBlock_0=TransformsBlock
TransformsBlock_Name=Transformation Pipeline
TransformsBlock_ParametersLabel=Parameters for stylesheet:
TransformsBlock_StylesheetsLabel=Stylesheets:
@@ -29,6 +30,10 @@
InputFileBlock_WORKSPACE_DIALOG_TITLE=File Selection
OutputTypeBlock_Group_Name=Output Type
+OutputFileBlock_0=Use default location
+OutputFileBlock_7=Location:
+OutputFileBlock_8=Open file on completion
+OutputFileBlock_9=Output File
OutputFileBlock_DIRECTORY_NOT_SPECIFIED=Transform output file not specified
OutputFileBlock_DIRECTORY_DOES_NOT_EXIST=Transform output file does not exist
OutputFileBlock_GROUP_NAME=Transform Output File
diff --git a/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/tabs/main/Messages.java b/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/tabs/main/Messages.java
new file mode 100644
index 0000000..d437bb4
--- /dev/null
+++ b/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/tabs/main/Messages.java
@@ -0,0 +1,22 @@
+package org.eclipse.wst.xsl.internal.debug.ui.tabs.main;
+
+import java.util.MissingResourceException;
+import java.util.ResourceBundle;
+
+public class Messages {
+ private static final String BUNDLE_NAME = "org.eclipse.wst.xsl.internal.debug.ui.tabs.main.messages"; //$NON-NLS-1$
+
+ private static final ResourceBundle RESOURCE_BUNDLE = ResourceBundle
+ .getBundle(BUNDLE_NAME);
+
+ private Messages() {
+ }
+
+ public static String getString(String key) {
+ try {
+ return RESOURCE_BUNDLE.getString(key);
+ } catch (MissingResourceException e) {
+ return '!' + key + '!';
+ }
+ }
+}
diff --git a/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/tabs/main/ParametersBlock.java b/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/tabs/main/ParametersBlock.java
index 290fec5..6b84317 100644
--- a/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/tabs/main/ParametersBlock.java
+++ b/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/tabs/main/ParametersBlock.java
@@ -110,7 +110,7 @@
TableColumn column1 = new TableColumn(fTable, SWT.NONE);
column1.setWidth(150);
column1.setResizable(true);
- column1.setText("Name");
+ column1.setText(Messages.getString("ParametersBlock.0")); //$NON-NLS-1$
column1.addSelectionListener(new SelectionAdapter()
{
@Override
@@ -123,7 +123,7 @@
TableColumn column2 = new TableColumn(fTable, SWT.NONE);
column2.setWidth(50);
column2.setResizable(true);
- column2.setText("Type");
+ column2.setText(Messages.getString("ParametersBlock.1")); //$NON-NLS-1$
column2.addSelectionListener(new SelectionAdapter()
{
@Override
@@ -136,7 +136,7 @@
TableColumn column3 = new TableColumn(fTable, SWT.NONE);
column3.setWidth(150);
column3.setResizable(true);
- column3.setText("Value");
+ column3.setText(Messages.getString("ParametersBlock.2")); //$NON-NLS-1$
column3.addSelectionListener(new SelectionAdapter()
{
@Override
@@ -159,7 +159,7 @@
});
parametersViewer.setColumnProperties(new String[]
- { "name", "type", "value" });
+ { Messages.getString("ParametersBlock.3"), Messages.getString("ParametersBlock.4"), Messages.getString("ParametersBlock.5") }); //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
final String[] types = new String[]
{ LaunchAttribute.TYPE_STRING, LaunchAttribute.TYPE_BOOLEAN, LaunchAttribute.TYPE_INT, LaunchAttribute.TYPE_DOUBLE, LaunchAttribute.TYPE_FLOAT, LaunchAttribute.TYPE_OBJECT,
LaunchAttribute.TYPE_CLASS, };
@@ -172,13 +172,13 @@
{
public boolean canModify(Object element, String property)
{
- return "type".equals(property) || "value".equals(property);
+ return Messages.getString("ParametersBlock.6").equals(property) || Messages.getString("ParametersBlock.7").equals(property); //$NON-NLS-1$ //$NON-NLS-2$
}
public Object getValue(Object element, String property)
{
LaunchAttribute att = (LaunchAttribute) element;
- if ("type".equals(property))
+ if (Messages.getString("ParametersBlock.8").equals(property)) //$NON-NLS-1$
{
for (int i = 0; i < types.length; i++)
{
@@ -188,19 +188,19 @@
}
return null;
}
- return att.value == null ? "" : att.value;
+ return att.value == null ? "" : att.value; //$NON-NLS-1$
}
public void modify(Object element, String property, Object value)
{
Item item = (Item) element;
LaunchAttribute att = (LaunchAttribute) item.getData();
- if ("type".equals(property))
+ if (Messages.getString("ParametersBlock.10").equals(property)) //$NON-NLS-1$
{
Integer v = (Integer) value;
att.type = types[v.intValue()];
}
- else if ("value".equals(property))
+ else if (Messages.getString("ParametersBlock.11").equals(property)) //$NON-NLS-1$
att.value = (String) value;
parametersViewer.update(att, null);
updateLaunchConfigurationDialog();
@@ -267,7 +267,7 @@
public String getName()
{
- return "Transformation Parameters";
+ return Messages.getString("ParametersBlock.9"); //$NON-NLS-1$
}
public void initializeFrom(ILaunchConfiguration configuration)
diff --git a/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/tabs/main/ParametersLabelProvider.java b/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/tabs/main/ParametersLabelProvider.java
index 5226057..9c9cc9c 100644
--- a/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/tabs/main/ParametersLabelProvider.java
+++ b/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/tabs/main/ParametersLabelProvider.java
@@ -29,7 +29,7 @@
case 2:
return p.value;
}
- return "!";
+ return "!"; //$NON-NLS-1$
}
public Image getColumnImage(Object element, int columnIndex)
diff --git a/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/tabs/main/StylesheetLabelProvider.java b/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/tabs/main/StylesheetLabelProvider.java
index 2f4141b..801e375 100644
--- a/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/tabs/main/StylesheetLabelProvider.java
+++ b/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/tabs/main/StylesheetLabelProvider.java
@@ -41,13 +41,13 @@
catch (CoreException e)
{
return MessageFormat.format(MainTabMessages.StylesheetEntryLabelProvider_Invalid_path, new String[]
- { "null" });
+ { "null" }); //$NON-NLS-1$
}
if (path == null)
{
return MessageFormat.format(MainTabMessages.StylesheetEntryLabelProvider_Invalid_path, new String[]
- { "null" });
+ { "null" }); //$NON-NLS-1$
}
else if (!path.isAbsolute() || !path.isValidPath(path.toString()))
{
@@ -60,7 +60,7 @@
if (segments.length > 0)
{
displayPath.append(segments[segments.length - 1]);
- displayPath.append(" - ");
+ displayPath.append(" - "); //$NON-NLS-1$
String device = path.getDevice();
if (device != null)
{
@@ -76,6 +76,6 @@
{
displayPath.append(path.toString());
}
- return (index + 1) + ") " + displayPath.toString();
+ return (index + 1) + ") " + displayPath.toString(); //$NON-NLS-1$
}
}
diff --git a/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/tabs/main/TransformsBlock.java b/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/tabs/main/TransformsBlock.java
index bed2da4..d358bbd 100644
--- a/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/tabs/main/TransformsBlock.java
+++ b/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/tabs/main/TransformsBlock.java
@@ -37,7 +37,7 @@
public class TransformsBlock extends AbstractTableBlock implements IStylesheetEntriesChangedListener
{
- protected static final String DIALOG_SETTINGS_PREFIX = "TransformsBlock";
+ protected static final String DIALOG_SETTINGS_PREFIX = MainTabMessages.TransformsBlock_0;
private StylesheetViewer stylesheetViewer;
private LaunchPipeline pipeline;
diff --git a/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/tabs/main/XSLMainTab.java b/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/tabs/main/XSLMainTab.java
index 40b44c3..49b3fd5 100644
--- a/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/tabs/main/XSLMainTab.java
+++ b/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/tabs/main/XSLMainTab.java
@@ -192,7 +192,7 @@
{
for (IResource resource : context)
{
- if (resource instanceof IFile && ("xml".equalsIgnoreCase(resource.getFileExtension()) || "xhtml".equalsIgnoreCase(resource.getFileExtension())))
+ if (resource instanceof IFile && ("xml".equalsIgnoreCase(resource.getFileExtension()) || "xhtml".equalsIgnoreCase(resource.getFileExtension()))) //$NON-NLS-1$ //$NON-NLS-2$
return (IFile) resource;
}
return null;
@@ -203,7 +203,7 @@
List<IResource> stylesheets = new ArrayList<IResource>();
for (IResource resource : context)
{
- if (resource instanceof IFile && "xsl".equalsIgnoreCase(resource.getFileExtension()))
+ if (resource instanceof IFile && "xsl".equalsIgnoreCase(resource.getFileExtension())) //$NON-NLS-1$
stylesheets.add(resource);
}
return (IFile[]) stylesheets.toArray(new IFile[0]);
diff --git a/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/tabs/main/messages.properties b/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/tabs/main/messages.properties
new file mode 100644
index 0000000..b6a38df
--- /dev/null
+++ b/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/tabs/main/messages.properties
@@ -0,0 +1,12 @@
+ParametersBlock.0=Name
+ParametersBlock.1=Type
+ParametersBlock.10=type
+ParametersBlock.11=value
+ParametersBlock.2=Value
+ParametersBlock.3=name
+ParametersBlock.4=type
+ParametersBlock.5=value
+ParametersBlock.6=type
+ParametersBlock.7=value
+ParametersBlock.8=type
+ParametersBlock.9=Transformation Parameters
diff --git a/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/tabs/output/Messages.java b/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/tabs/output/Messages.java
new file mode 100644
index 0000000..187fede
--- /dev/null
+++ b/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/tabs/output/Messages.java
@@ -0,0 +1,25 @@
+package org.eclipse.wst.xsl.internal.debug.ui.tabs.output;
+
+import org.eclipse.osgi.util.NLS;
+
+public class Messages extends NLS {
+ private static final String BUNDLE_NAME = "org.eclipse.wst.xsl.internal.debug.ui.tabs.output.messages"; //$NON-NLS-1$
+ public static String OutputPropertiesBlock_0;
+ public static String OutputPropertiesBlock_1;
+ public static String OutputPropertiesBlock_13;
+ public static String OutputPropertiesBlock_3;
+ public static String OutputPropertiesBlock_4;
+ public static String OutputPropertiesBlock_5;
+ public static String OutputPropertiesBlock_7;
+ public static String OutputPropertiesBlock_8;
+ public static String OutputPropertiesBlock_9;
+ public static String OutputTab_0;
+ public static String OutputTab_1;
+ static {
+ // initialize resource bundle
+ NLS.initializeMessages(BUNDLE_NAME, Messages.class);
+ }
+
+ private Messages() {
+ }
+}
diff --git a/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/tabs/output/OutputFileBlock.java b/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/tabs/output/OutputFileBlock.java
index 9b261c6..065e39d 100644
--- a/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/tabs/output/OutputFileBlock.java
+++ b/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/tabs/output/OutputFileBlock.java
@@ -30,11 +30,11 @@
public class OutputFileBlock extends ResourceSelectionBlock
{
- public static final String OUTPUT_METHOD_DEFAULT = "<Default>";
- public static final String OUTPUT_METHOD_XML = "xml";
- public static final String OUTPUT_METHOD_XHTML = "xhtml";
- public static final String OUTPUT_METHOD_HTML = "html";
- public static final String OUTPUT_METHOD_TEXT = "text";
+ public static final String OUTPUT_METHOD_DEFAULT = "<Default>"; //$NON-NLS-1$
+ public static final String OUTPUT_METHOD_XML = "xml"; //$NON-NLS-1$
+ public static final String OUTPUT_METHOD_XHTML = "xhtml"; //$NON-NLS-1$
+ public static final String OUTPUT_METHOD_HTML = "html"; //$NON-NLS-1$
+ public static final String OUTPUT_METHOD_TEXT = "text"; //$NON-NLS-1$
public static final String[] OUTPUT_METHODS = new String[]
{ OUTPUT_METHOD_DEFAULT, OUTPUT_METHOD_XML, OUTPUT_METHOD_XHTML, OUTPUT_METHOD_HTML, OUTPUT_METHOD_TEXT };
@@ -61,7 +61,7 @@
case GROUP_NAME:
return getName();
case USE_DEFAULT_RADIO:
- return "Use default location";
+ return MainTabMessages.OutputFileBlock_0;
case USE_OTHER_RADIO:
return MainTabMessages.OutputFOFileBlock_OTHER_RADIO;
case DIRECTORY_DIALOG_MESSAGE:
@@ -77,7 +77,7 @@
case WORKSPACE_DIALOG_TITLE:
return MainTabMessages.OutputFOFileBlock_WORKSPACE_DIALOG_TITLE;
}
- return "" + type;
+ return "" + type; //$NON-NLS-1$
}
@Override
@@ -105,7 +105,7 @@
// methodViewer.setSelection(new StructuredSelection("xml"), true);
// formatViewer.setSelection(new StructuredSelection("<none>"), true);
- fileLabel = "Location:";
+ fileLabel = MainTabMessages.OutputFileBlock_7;
createCheckboxAndText(parent);
createButtons(parent);
}
@@ -113,7 +113,7 @@
@Override
protected void createButtons(Composite parent)
{
- openFileCheckButton = createCheckButton(parent, "Open file on completion");
+ openFileCheckButton = createCheckButton(parent, MainTabMessages.OutputFileBlock_8);
GridData gd = new GridData(GridData.HORIZONTAL_ALIGN_BEGINNING);
gd.horizontalSpan = 1;
openFileCheckButton.setLayoutData(gd);
@@ -152,7 +152,7 @@
public String getName()
{
- return "Output File";
+ return MainTabMessages.OutputFileBlock_9;
}
public void initializeFrom(ILaunchConfiguration configuration)
@@ -163,7 +163,7 @@
// methodViewer.setSelection(new StructuredSelection(outputMethod),
// true);
- inputFilename = configuration.getAttribute(XSLLaunchConfigurationConstants.ATTR_INPUT_FILE, "");
+ inputFilename = configuration.getAttribute(XSLLaunchConfigurationConstants.ATTR_INPUT_FILE, ""); //$NON-NLS-1$
// String renderTo =
// configuration.getAttribute(XSLLaunchConfigurationConstants.ATTR_RENDER_TO,
// "");
@@ -207,7 +207,7 @@
public void setDefaults(ILaunchConfigurationWorkingCopy configuration)
{
configuration.setAttribute(XSLLaunchConfigurationConstants.ATTR_USE_DEFAULT_OUTPUT_FILE, true);
- configuration.setAttribute(XSLLaunchConfigurationConstants.ATTR_OUTPUT_FILE, "");
+ configuration.setAttribute(XSLLaunchConfigurationConstants.ATTR_OUTPUT_FILE, ""); //$NON-NLS-1$
configuration.setAttribute(XSLLaunchConfigurationConstants.ATTR_OUTPUT_METHOD, (String) null);
configuration.setAttribute(XSLLaunchConfigurationConstants.ATTR_OPEN_FILE, true);
}
@@ -224,9 +224,9 @@
int index = inputFilename.lastIndexOf('.');
if (index != -1)
file = inputFilename.substring(0, index);
- file += ".out." + method;
- if (inputFilename.trim().endsWith("}"))
- file += "}";
+ file += ".out." + method; //$NON-NLS-1$
+ if (inputFilename.trim().endsWith("}")) //$NON-NLS-1$
+ file += "}"; //$NON-NLS-1$
defaultOutputFile = file;
diff --git a/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/tabs/output/OutputPropertiesBlock.java b/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/tabs/output/OutputPropertiesBlock.java
index 58cbb6f..54c3494 100644
--- a/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/tabs/output/OutputPropertiesBlock.java
+++ b/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/tabs/output/OutputPropertiesBlock.java
@@ -96,7 +96,7 @@
usePropertiesFromPreferencesRadio = new Button(parent, SWT.RADIO);
GridData gd = new GridData(SWT.LEFT, SWT.CENTER, false, false);
usePropertiesFromPreferencesRadio.setLayoutData(gd);
- usePropertiesFromPreferencesRadio.setText("Use properties from preferences");
+ usePropertiesFromPreferencesRadio.setText(Messages.OutputPropertiesBlock_0);
usePropertiesFromPreferencesRadio.addSelectionListener(new SelectionListener()
{
@@ -112,7 +112,7 @@
});
changePreferences = new Button(parent, SWT.PUSH);
- changePreferences.setText("Change Preferences...");
+ changePreferences.setText(Messages.OutputPropertiesBlock_1);
gd = new GridData(SWT.RIGHT, SWT.CENTER, false, false);
changePreferences.setLayoutData(gd);
changePreferences.addSelectionListener(new SelectionAdapter()
@@ -121,7 +121,7 @@
public void widgetSelected(SelectionEvent e)
{
IPreferencePage page = new OutputPreferencePage();
- XSLDebugUIPlugin.showPreferencePage("org.eclipse.wst.xsl.debug.ui.output", page);
+ XSLDebugUIPlugin.showPreferencePage("org.eclipse.wst.xsl.debug.ui.output", page); //$NON-NLS-1$
handleUsePropertiesFromPreferences(true);
}
});
@@ -129,7 +129,7 @@
useSpecificPropertiesRadio = new Button(parent, SWT.RADIO);
gd = new GridData(SWT.LEFT, SWT.CENTER, false, false);
useSpecificPropertiesRadio.setLayoutData(gd);
- useSpecificPropertiesRadio.setText("Use specific properties");
+ useSpecificPropertiesRadio.setText(Messages.OutputPropertiesBlock_3);
useSpecificPropertiesRadio.addSelectionListener(new SelectionListener()
{
@@ -160,12 +160,12 @@
TableColumn c1 = new TableColumn(table, SWT.NONE);
c1.setWidth(150);
c1.setResizable(true);
- c1.setText("Property");
+ c1.setText(Messages.OutputPropertiesBlock_4);
TableColumn c2 = new TableColumn(table, SWT.NONE);
c2.setWidth(250);
c2.setResizable(true);
- c2.setText("Value");
+ c2.setText(Messages.OutputPropertiesBlock_5);
tViewer = new TableViewer(table);
tViewer.setContentProvider(new IStructuredContentProvider()
@@ -203,7 +203,7 @@
case 1:
return launchProperties.getProperty(prop);
}
- return "!!";
+ return "!!"; //$NON-NLS-1$
}
public void addListener(ILabelProviderListener listener)
@@ -225,12 +225,12 @@
});
tViewer.setColumnProperties(new String[]
- { "property", "value" });
+ { Messages.OutputPropertiesBlock_7, Messages.OutputPropertiesBlock_8 });
tViewer.setCellModifier(new ICellModifier()
{
public boolean canModify(Object element, String property)
{
- if (!"value".equals(property))
+ if (!Messages.OutputPropertiesBlock_9.equals(property))
return false;
return true;
}
@@ -239,14 +239,14 @@
{
String prop = (String) element;
String value = launchProperties.getProperty(prop);
- return value == null ? "" : value;
+ return value == null ? "" : value; //$NON-NLS-1$
}
public void modify(Object element, String property, Object value)
{
Item item = (Item) element;
String prop = (String) item.getData();
- if (value == null || "".equals(value))
+ if (value == null || "".equals(value)) //$NON-NLS-1$
launchProperties.removeProperty(prop);
else
launchProperties.setProperty(prop, (String) value);
@@ -290,7 +290,7 @@
}
}
}
- descriptionText.setText(text == null ? "" : text);
+ descriptionText.setText(text == null ? "" : text); //$NON-NLS-1$
}
});
@@ -339,7 +339,7 @@
public String getName()
{
- return "Output Properties";
+ return Messages.OutputPropertiesBlock_13;
}
private LaunchProperties initializeFeaturesFromPreferences()
diff --git a/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/tabs/output/OutputTab.java b/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/tabs/output/OutputTab.java
index 89ecc41..1cca556 100644
--- a/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/tabs/output/OutputTab.java
+++ b/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/tabs/output/OutputTab.java
@@ -44,7 +44,7 @@
outputFileBlock.createControl(comp);
Group group = new Group(comp, SWT.NULL);
- group.setText("Output Properties");
+ group.setText(Messages.OutputTab_0);
GridData gd = new GridData(SWT.FILL, SWT.FILL, true, true);
group.setLayoutData(gd);
layout = new GridLayout(2, false);
@@ -55,6 +55,6 @@
public String getName()
{
- return "Output";
+ return Messages.OutputTab_1;
}
}
diff --git a/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/tabs/output/messages.properties b/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/tabs/output/messages.properties
new file mode 100644
index 0000000..851fbb3
--- /dev/null
+++ b/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/tabs/output/messages.properties
@@ -0,0 +1,11 @@
+OutputPropertiesBlock_0=Use properties from preferences
+OutputPropertiesBlock_1=Change Preferences...
+OutputPropertiesBlock_13=Output Properties
+OutputPropertiesBlock_3=Use specific properties
+OutputPropertiesBlock_4=Property
+OutputPropertiesBlock_5=Value
+OutputPropertiesBlock_7=property
+OutputPropertiesBlock_8=value
+OutputPropertiesBlock_9=value
+OutputTab_0=Output Properties
+OutputTab_1=Output
diff --git a/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/tabs/processor/FeaturesBlock.java b/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/tabs/processor/FeaturesBlock.java
index f026e8c..be98df2 100644
--- a/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/tabs/processor/FeaturesBlock.java
+++ b/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/tabs/processor/FeaturesBlock.java
@@ -114,7 +114,7 @@
useFeaturesFromPreferencesRadio = new Button(group, SWT.RADIO);
gd = new GridData(SWT.LEFT, SWT.CENTER, false, false);
useFeaturesFromPreferencesRadio.setLayoutData(gd);
- useFeaturesFromPreferencesRadio.setText("Use features from preferences");
+ useFeaturesFromPreferencesRadio.setText(Messages.getString("FeaturesBlock.0")); //$NON-NLS-1$
useFeaturesFromPreferencesRadio.addSelectionListener(new SelectionListener()
{
@@ -130,7 +130,7 @@
});
changePreferences = new Button(group, SWT.PUSH);
- changePreferences.setText("Change Preferences...");
+ changePreferences.setText(Messages.getString("FeaturesBlock.1")); //$NON-NLS-1$
gd = new GridData(SWT.RIGHT, SWT.CENTER, false, false);
changePreferences.setLayoutData(gd);
changePreferences.addSelectionListener(new SelectionAdapter()
@@ -139,7 +139,7 @@
public void widgetSelected(SelectionEvent e)
{
IPreferencePage page = new FeaturesPreferencePage();
- XSLDebugUIPlugin.showPreferencePage("org.eclipse.wst.xsl.debug.ui.page1", page);
+ XSLDebugUIPlugin.showPreferencePage("org.eclipse.wst.xsl.debug.ui.page1", page); //$NON-NLS-1$
// now refresh everything
handleUseFeaturesFromPreferences(true);
// tViewer.refresh();
@@ -149,7 +149,7 @@
useSpecificFeaturesRadio = new Button(group, SWT.RADIO);
gd = new GridData(SWT.LEFT, SWT.CENTER, false, false);
useSpecificFeaturesRadio.setLayoutData(gd);
- useSpecificFeaturesRadio.setText("Use specific features");
+ useSpecificFeaturesRadio.setText(Messages.getString("FeaturesBlock.3")); //$NON-NLS-1$
useSpecificFeaturesRadio.addSelectionListener(new SelectionListener()
{
@@ -178,17 +178,17 @@
TableColumn c1 = new TableColumn(table, SWT.NONE);
c1.setWidth(150);
c1.setResizable(true);
- c1.setText("Feature");
+ c1.setText(Messages.getString("FeaturesBlock.4")); //$NON-NLS-1$
TableColumn c2 = new TableColumn(table, SWT.NONE);
c2.setWidth(50);
c2.setResizable(true);
- c2.setText("Type");
+ c2.setText(Messages.getString("FeaturesBlock.5")); //$NON-NLS-1$
TableColumn c3 = new TableColumn(table, SWT.NONE);
c3.setWidth(250);
c3.setResizable(true);
- c3.setText("Value");
+ c3.setText(Messages.getString("FeaturesBlock.6")); //$NON-NLS-1$
tViewer = new TableViewer(table);
tViewer.setContentProvider(new IStructuredContentProvider()
@@ -229,9 +229,9 @@
return tv.type;
case 2:
String value = tv.value;
- return value == null ? "" : value;
+ return value == null ? "" : value; //$NON-NLS-1$
}
- return "!!";
+ return "!!"; //$NON-NLS-1$
}
private String removeURI(String uri)
@@ -261,25 +261,25 @@
});
tViewer.setColumnProperties(new String[]
- { "name", "type", "value" });
+ { Messages.getString("FeaturesBlock.9"), Messages.getString("FeaturesBlock.10"), Messages.getString("FeaturesBlock.11") }); //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
tViewer.setCellModifier(new ICellModifier()
{
public boolean canModify(Object element, String property)
{
- return "value".equals(property);
+ return Messages.getString("FeaturesBlock.12").equals(property); //$NON-NLS-1$
}
public Object getValue(Object element, String property)
{
LaunchAttribute tv = (LaunchAttribute) element;
- return tv.value == null ? "" : tv.value;
+ return tv.value == null ? "" : tv.value; //$NON-NLS-1$
}
public void modify(Object element, String property, Object value)
{
Item item = (Item) element;
LaunchAttribute tv = (LaunchAttribute) item.getData();
- if (value == null || "".equals(value))
+ if (value == null || "".equals(value)) //$NON-NLS-1$
launchFeatures.removeFeature(tv.uri);
else
tv.setValue((String) value);
@@ -357,7 +357,7 @@
}
text = feature == null ? null : feature.getDescription();
}
- descriptionText.setText(text == null ? "" : text);
+ descriptionText.setText(text == null ? "" : text); //$NON-NLS-1$
}
});
@@ -438,7 +438,7 @@
public String getName()
{
- return "Processor Features";
+ return Messages.getString("FeaturesBlock.16"); //$NON-NLS-1$
}
public void setDefaults(ILaunchConfigurationWorkingCopy configuration)
diff --git a/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/tabs/processor/InstallStandin.java b/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/tabs/processor/InstallStandin.java
index 17d67b7..5e78ade 100644
--- a/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/tabs/processor/InstallStandin.java
+++ b/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/tabs/processor/InstallStandin.java
@@ -24,6 +24,6 @@
public InstallStandin(String id, String name, String typeId, String debuggerId, IProcessorJar[] jars)
{
- super(id, name, typeId, jars, debuggerId, "", false);
+ super(id, name, typeId, jars, debuggerId, "", false); //$NON-NLS-1$
}
}
diff --git a/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/tabs/processor/JarLabelProvider.java b/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/tabs/processor/JarLabelProvider.java
index 72dab38..7685d12 100644
--- a/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/tabs/processor/JarLabelProvider.java
+++ b/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/tabs/processor/JarLabelProvider.java
@@ -21,6 +21,6 @@
{
IProcessorJar jar = (IProcessorJar) element;
IPath path = jar.getPath();
- return path.lastSegment() + " - " + path.removeLastSegments(1).toOSString() + "";
+ return path.lastSegment() + " - " + path.removeLastSegments(1).toOSString() + ""; //$NON-NLS-1$ //$NON-NLS-2$
}
}
diff --git a/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/tabs/processor/Messages.java b/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/tabs/processor/Messages.java
new file mode 100644
index 0000000..1590113
--- /dev/null
+++ b/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/tabs/processor/Messages.java
@@ -0,0 +1,22 @@
+package org.eclipse.wst.xsl.internal.debug.ui.tabs.processor;
+
+import java.util.MissingResourceException;
+import java.util.ResourceBundle;
+
+public class Messages {
+ private static final String BUNDLE_NAME = "org.eclipse.wst.xsl.internal.debug.ui.tabs.processor.messages"; //$NON-NLS-1$
+
+ private static final ResourceBundle RESOURCE_BUNDLE = ResourceBundle
+ .getBundle(BUNDLE_NAME);
+
+ private Messages() {
+ }
+
+ public static String getString(String key) {
+ try {
+ return RESOURCE_BUNDLE.getString(key);
+ } catch (MissingResourceException e) {
+ return '!' + key + '!';
+ }
+ }
+}
diff --git a/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/tabs/processor/ProcessorBlock.java b/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/tabs/processor/ProcessorBlock.java
index d99ffd3..ef8730e 100644
--- a/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/tabs/processor/ProcessorBlock.java
+++ b/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/tabs/processor/ProcessorBlock.java
@@ -64,10 +64,10 @@
group.setLayout(new GridLayout(2, false));
group.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
group.setFont(font);
- group.setText("XSLT Processor");
+ group.setText(ProcessorMessages.ProcessorBlock_0);
usePreferencesRadio = new Button(group, SWT.RADIO);
- usePreferencesRadio.setText("Use processor from preferences");
+ usePreferencesRadio.setText(ProcessorMessages.ProcessorBlock_1);
usePreferencesRadio.addSelectionListener(new SelectionAdapter()
{
@Override
@@ -79,7 +79,7 @@
});
alterPreferencesButton = new Button(group, SWT.PUSH);
- alterPreferencesButton.setText("Change preferences...");
+ alterPreferencesButton.setText(ProcessorMessages.ProcessorBlock_2);
GridData gd = new GridData(GridData.HORIZONTAL_ALIGN_END);
gd.widthHint = 150;
alterPreferencesButton.setLayoutData(gd);
@@ -89,12 +89,12 @@
public void widgetSelected(SelectionEvent e)
{
IPreferencePage page = new ProcessorsPreferencePage();
- showPrefPage("org.eclipse.wst.xslt.launching.ui.preferences.ProcessorPreferencePage", page);
+ showPrefPage("org.eclipse.wst.xslt.launching.ui.preferences.ProcessorPreferencePage", page); //$NON-NLS-1$
}
});
overridePreferencesRadio = new Button(group, SWT.RADIO);
- overridePreferencesRadio.setText("Use specific processor");
+ overridePreferencesRadio.setText(ProcessorMessages.ProcessorBlock_4);
overridePreferencesRadio.addSelectionListener(new SelectionAdapter()
{
@Override
@@ -116,7 +116,7 @@
public void widgetSelected(SelectionEvent e)
{
IPreferencePage page = new ProcessorsPreferencePage();
- showPrefPage("org.eclipse.wst.xslt.launching.ui.preferences.ProcessorPreferencePage", page);
+ showPrefPage("org.eclipse.wst.xslt.launching.ui.preferences.ProcessorPreferencePage", page); //$NON-NLS-1$
}
});
@@ -131,7 +131,7 @@
settingsComp.setFont(font);
Label label = new Label(settingsComp, SWT.NONE);
- label.setText("Processor:");
+ label.setText(ProcessorMessages.ProcessorBlock_6);
runCombo = new Combo(settingsComp, SWT.READ_ONLY | SWT.SINGLE);
runCombo.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
runComboViewer = new ComboViewer(runCombo);
@@ -180,7 +180,7 @@
public String getName()
{
- return "Processor";
+ return ProcessorMessages.ProcessorBlock_7;
}
public void initializeFrom(ILaunchConfiguration configuration)
diff --git a/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/tabs/processor/ProcessorDetailsDialog.java b/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/tabs/processor/ProcessorDetailsDialog.java
index 47265e2..dba9e2b 100644
--- a/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/tabs/processor/ProcessorDetailsDialog.java
+++ b/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/tabs/processor/ProcessorDetailsDialog.java
@@ -88,7 +88,7 @@
*/
protected String getDialogSettingsSectionName()
{
- return "XSL_DETAILS_DIALOG_SECTION";
+ return "XSL_DETAILS_DIALOG_SECTION"; //$NON-NLS-1$
}
@Override
diff --git a/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/tabs/processor/ProcessorMessages.java b/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/tabs/processor/ProcessorMessages.java
index c9e318b..98450fa 100644
--- a/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/tabs/processor/ProcessorMessages.java
+++ b/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/tabs/processor/ProcessorMessages.java
@@ -14,7 +14,19 @@
public final class ProcessorMessages extends NLS
{
- private static final String BUNDLE_NAME = "org.eclipse.wst.xsl.internal.debug.ui.tabs.processor.ProcessorMessages";
+ private static final String BUNDLE_NAME = "org.eclipse.wst.xsl.internal.debug.ui.tabs.processor.ProcessorMessages"; //$NON-NLS-1$
+
+ public static String ProcessorBlock_0;
+
+ public static String ProcessorBlock_1;
+
+ public static String ProcessorBlock_2;
+
+ public static String ProcessorBlock_4;
+
+ public static String ProcessorBlock_6;
+
+ public static String ProcessorBlock_7;
public static String ProcessorsComboBlock;
public static String ProcessorsComboBlock_0;
@@ -23,6 +35,24 @@
public static String InputFileBlock_WORKSPACE_DIALOG_TITLE;
+ public static String InstalledProcessorsBlock_0;
+
+ public static String InstalledProcessorsBlock_1;
+
+ public static String InstalledProcessorsBlock_2;
+
+ public static String InstalledProcessorsBlock_3;
+
+ public static String InstalledProcessorsBlock_4;
+
+ public static String InstalledProcessorsBlock_5;
+
+ public static String InstalledProcessorsBlock_6;
+
+ public static String InstalledProcessorsBlock_7;
+
+ public static String InstalledProcessorsBlock_8;
+
public static String ProcessorDetailsDialog_Title;
public static String ProcessorDetailsDialog_installName;
@@ -31,6 +61,10 @@
public static String ProcessorDetailsDialog_installClasspath;
+ public static String AddProcessorDialog_1;
+
+ public static String AddProcessorDialog_7;
+
public static String AddProcessorDialog_Edit_Title;
public static String AddProcessorDialog_Add_Title;
@@ -43,6 +77,8 @@
public static String AddProcessorDialog_processorType;
+ public static String ProcessorLibraryBlock_6;
+
public static String ProcessorLibraryBlock_AddButton;
public static String ProcessorLibraryBlock_RemoveButton;
@@ -63,6 +99,12 @@
public static String ProcessorsUpdater;
+ public static String WorkingDirectoryBlock_1;
+
+ public static String WorkingDirectoryBlock_2;
+
+ public static String WorkingDirectoryBlock_3;
+
public static String WorkingDirectoryBlock_DIRECTORY_NOT_SPECIFIED;
public static String WorkingDirectoryBlock_DIRECTORY_DOES_NOT_EXIST;
public static String WorkingDirectoryBlock_DEFAULT_RADIO;
@@ -74,6 +116,14 @@
public static String WorkingDirectoryBlock_WORKSPACE_BUTTON;
public static String WorkingDirectoryBlock_WORKSPACE_DIALOG_TITLE;
+ public static String URIResolverBlock_3;
+
+ public static String URIResolverBlock_5;
+
+ public static String URIResolverBlock_6;
+
+ public static String URIResolverBlock_8;
+
public static String URIResolverBlock_DIRECTORY_NOT_SPECIFIED;
public static String URIResolverBlock_DIRECTORY_DOES_NOT_EXIST;
public static String URIResolverBlock_DEFAULT_RADIO;
diff --git a/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/tabs/processor/ProcessorMessages.properties b/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/tabs/processor/ProcessorMessages.properties
index 0086680..99167b1 100644
--- a/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/tabs/processor/ProcessorMessages.properties
+++ b/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/tabs/processor/ProcessorMessages.properties
@@ -1,3 +1,9 @@
+ProcessorBlock_0=XSLT Processor
+ProcessorBlock_1=Use processor from preferences
+ProcessorBlock_2=Change preferences...
+ProcessorBlock_4=Use specific processor
+ProcessorBlock_6=Processor:
+ProcessorBlock_7=Processor
ProcessorsComboBlock=XSLT Processor
ProcessorsComboBlock_0=No XSLT processors defined in workspace
ProcessorsComboBlock_1=&Installed processors...
@@ -25,6 +31,10 @@
URIResolverBlock_12=Base directory for resolving URIs
URIResolverBlock_10=Base directory does not exist
URIResolverBlock_20=Base directory not specified
+URIResolverBlock_3=URI Resolver
+URIResolverBlock_5=Relative to working directory
+URIResolverBlock_6=Relative to (1st) stylesheet
+URIResolverBlock_8=Specific Location:
URIResolverBlock_Working_Directory_8=URI Resolver
URIResolverBlock_WORKSPACE_DIALOG_TITLE=Folder Selection
@@ -33,6 +43,8 @@
ProcessorDetailsDialog_installType=Type:
ProcessorDetailsDialog_installClasspath=Libraries:
+AddProcessorDialog_1=Supported versions:
+AddProcessorDialog_7=Processor must support at least one XSLT version
AddProcessorDialog_Edit_Title=Edit Processor
AddProcessorDialog_Add_Title=Add Processor
AddProcessorDialog_processorName=Processor Name:
@@ -42,7 +54,17 @@
AddProcessorDialog_enterName=A name must be entered for this processor
AddProcessorDialog_duplicateName=The name has already been used
AddProcessorDialog_Processor_name_must_be_a_valid_file_name=Processor name must be a valid file name
+InstalledProcessorsBlock_0=Installed Java XSLT Processors:
+InstalledProcessorsBlock_1=Name
+InstalledProcessorsBlock_2=Type
+InstalledProcessorsBlock_3=XSLT Versions
+InstalledProcessorsBlock_4=Debugger
+InstalledProcessorsBlock_5=Add
+InstalledProcessorsBlock_6=Edit
+InstalledProcessorsBlock_7=Remove
+InstalledProcessorsBlock_8=None
+ProcessorLibraryBlock_6=One or more jar files must be specified
ProcessorLibraryBlock_AddButton=Add External JARs
ProcessorLibraryBlock_AddWorkspaceButton=Add Workspace JARs
ProcessorLibraryBlock_RemoveButton=Remove
@@ -53,6 +75,9 @@
ProcessorsUpdater=Save processor settings
+WorkingDirectoryBlock_1=Default:
+WorkingDirectoryBlock_2=Other:
+WorkingDirectoryBlock_3=Working Directory
WorkingDirectoryBlock_DIRECTORY_NOT_SPECIFIED=Working directory not specified
WorkingDirectoryBlock_DIRECTORY_DOES_NOT_EXIST=Working directory does not exist
WorkingDirectoryBlock_DEFAULT_RADIO=Workspace default
diff --git a/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/tabs/processor/XSLProcessorTab.java b/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/tabs/processor/XSLProcessorTab.java
index 6714b9d..a752872 100644
--- a/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/tabs/processor/XSLProcessorTab.java
+++ b/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/tabs/processor/XSLProcessorTab.java
@@ -55,7 +55,7 @@
public String getName()
{
- return "Processor";
+ return Messages.getString("XSLProcessorTab.0"); //$NON-NLS-1$
}
@Override
diff --git a/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/tabs/processor/messages.properties b/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/tabs/processor/messages.properties
new file mode 100644
index 0000000..f5020aa
--- /dev/null
+++ b/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/tabs/processor/messages.properties
@@ -0,0 +1,12 @@
+FeaturesBlock.0=Use features from preferences
+FeaturesBlock.1=Change Preferences...
+FeaturesBlock.10=type
+FeaturesBlock.11=value
+FeaturesBlock.12=value
+FeaturesBlock.16=Processor Features
+FeaturesBlock.3=Use specific features
+FeaturesBlock.4=Feature
+FeaturesBlock.5=Type
+FeaturesBlock.6=Value
+FeaturesBlock.9=name
+XSLProcessorTab.0=Processor
diff --git a/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/tabs/resolver/Messages.java b/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/tabs/resolver/Messages.java
new file mode 100644
index 0000000..594e014
--- /dev/null
+++ b/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/tabs/resolver/Messages.java
@@ -0,0 +1,22 @@
+package org.eclipse.wst.xsl.internal.debug.ui.tabs.resolver;
+
+import java.util.MissingResourceException;
+import java.util.ResourceBundle;
+
+public class Messages {
+ private static final String BUNDLE_NAME = "org.eclipse.wst.xsl.internal.debug.ui.tabs.resolver.messages"; //$NON-NLS-1$
+
+ private static final ResourceBundle RESOURCE_BUNDLE = ResourceBundle
+ .getBundle(BUNDLE_NAME);
+
+ private Messages() {
+ }
+
+ public static String getString(String key) {
+ try {
+ return RESOURCE_BUNDLE.getString(key);
+ } catch (MissingResourceException e) {
+ return '!' + key + '!';
+ }
+ }
+}
diff --git a/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/tabs/resolver/URIResolverBlock.java b/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/tabs/resolver/URIResolverBlock.java
index 868cb2c..190bec9 100644
--- a/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/tabs/resolver/URIResolverBlock.java
+++ b/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/tabs/resolver/URIResolverBlock.java
@@ -64,7 +64,7 @@
case WORKSPACE_DIALOG_TITLE:
return ProcessorMessages.URIResolverBlock_WORKSPACE_DIALOG_TITLE;
}
- return "" + type;
+ return "" + type; //$NON-NLS-1$
}
@Override
@@ -74,7 +74,7 @@
public String getName()
{
- return "URI Resolver";
+ return ProcessorMessages.URIResolverBlock_3;
}
public void initializeFrom(ILaunchConfiguration configuration)
@@ -113,19 +113,19 @@
}
};
- workingDirRelativeRadio = createRadioButton(specificFileComp, "Relative to working directory");
+ workingDirRelativeRadio = createRadioButton(specificFileComp, ProcessorMessages.URIResolverBlock_5);
gd = new GridData();
gd.horizontalSpan = 2;
workingDirRelativeRadio.setLayoutData(gd);
workingDirRelativeRadio.addSelectionListener(listener);
- stylesheetRelativeRadio = createRadioButton(specificFileComp, "Relative to (1st) stylesheet");
+ stylesheetRelativeRadio = createRadioButton(specificFileComp, ProcessorMessages.URIResolverBlock_6);
gd = new GridData();
gd.horizontalSpan = 2;
stylesheetRelativeRadio.setLayoutData(gd);
stylesheetRelativeRadio.addSelectionListener(listener);
- otherRadio = createRadioButton(specificFileComp, "Specific Location:");
+ otherRadio = createRadioButton(specificFileComp, ProcessorMessages.URIResolverBlock_8);
gd = new GridData();
gd.horizontalSpan = 1;
otherRadio.setLayoutData(gd);
@@ -144,11 +144,11 @@
{
if (useDefault)
{
- resourceText.setText(defaultOutputFile == null ? "" : defaultOutputFile);
+ resourceText.setText(defaultOutputFile == null ? "" : defaultOutputFile); //$NON-NLS-1$
}
else
{
- resourceText.setText(outputFile == null ? "" : outputFile);
+ resourceText.setText(outputFile == null ? "" : outputFile); //$NON-NLS-1$
}
updateEnablement(useDefault);
}
diff --git a/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/tabs/resolver/URIResolverBlock2.java b/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/tabs/resolver/URIResolverBlock2.java
index 5df16c7..13f8c82 100644
--- a/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/tabs/resolver/URIResolverBlock2.java
+++ b/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/tabs/resolver/URIResolverBlock2.java
@@ -40,7 +40,7 @@
private Button customRadio;
private Text customText;
private final ResolverType[] resolverTypes = new ResolverType[]
- { new ResolverType("N/A", "Working Directory (default)"), new ResolverType("org.eclipse.wst.some.resolver.type.1", "Stylesheet") };
+ { new ResolverType(Messages.getString("URIResolverBlock2.0"), Messages.getString("URIResolverBlock2.1")), new ResolverType("org.eclipse.wst.some.resolver.type.1", Messages.getString("URIResolverBlock2.3")) }; //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$ //$NON-NLS-4$
private Button defaultRadio;
private Combo combo;
@@ -59,7 +59,7 @@
setControl(group);
defaultRadio = new Button(group, SWT.RADIO);
- defaultRadio.setText("Resolve relative to:");
+ defaultRadio.setText(Messages.getString("URIResolverBlock2.4")); //$NON-NLS-1$
defaultRadio.setFont(font);
defaultRadio.addSelectionListener(new SelectionAdapter()
{
@@ -111,7 +111,7 @@
});
customRadio = new Button(group, SWT.RADIO);
- customRadio.setText("Use custom URI resolver (Note: class must be included on classpath)");
+ customRadio.setText(Messages.getString("URIResolverBlock2.5")); //$NON-NLS-1$
gd = new GridData(GridData.FILL_HORIZONTAL);
customRadio.setLayoutData(gd);
gd.horizontalSpan = 2;
@@ -138,7 +138,7 @@
textComp.setFont(font);
Label label = new Label(textComp, SWT.NONE);
- label.setText("Class:");
+ label.setText(Messages.getString("URIResolverBlock2.6")); //$NON-NLS-1$
customText = new Text(textComp, SWT.BORDER);
gd = new GridData(GridData.FILL_HORIZONTAL);
@@ -156,7 +156,7 @@
public String getName()
{
- return "URI Resolver";
+ return Messages.getString("URIResolverBlock2.7"); //$NON-NLS-1$
}
@Override
@@ -165,7 +165,7 @@
String text = customText.getText();
if (customRadio.getSelection() && (text == null || text.length() == 0))
{
- setErrorMessage("Missing URI Resolver class name");
+ setErrorMessage(Messages.getString("URIResolverBlock2.8")); //$NON-NLS-1$
return false;
}
return super.isValid(launchConfig);
diff --git a/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/tabs/resolver/WorkingDirectoryBlock.java b/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/tabs/resolver/WorkingDirectoryBlock.java
index b8f9711..9ac720e 100644
--- a/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/tabs/resolver/WorkingDirectoryBlock.java
+++ b/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/tabs/resolver/WorkingDirectoryBlock.java
@@ -68,7 +68,7 @@
case WORKSPACE_DIALOG_TITLE:
return ProcessorMessages.WorkingDirectoryBlock_WORKSPACE_DIALOG_TITLE;
}
- return "" + type;
+ return "" + type; //$NON-NLS-1$
}
@Override
@@ -84,7 +84,7 @@
gd.horizontalSpan = 2;
specificFileComp.setLayoutData(gd);
- useDefaultCheckButton = createRadioButton(specificFileComp, "Default:");
+ useDefaultCheckButton = createRadioButton(specificFileComp, ProcessorMessages.WorkingDirectoryBlock_1);
useDefaultCheckButton.addSelectionListener(widgetListener);
defaultText = new Text(specificFileComp, SWT.SINGLE | SWT.BORDER);
@@ -93,7 +93,7 @@
defaultText.setFont(parent.getFont());
defaultText.setEnabled(false);
- useSpecificButton = createRadioButton(specificFileComp, "Other:");
+ useSpecificButton = createRadioButton(specificFileComp, ProcessorMessages.WorkingDirectoryBlock_2);
resourceText = new Text(specificFileComp, SWT.SINGLE | SWT.BORDER);
gd = new GridData(GridData.FILL_HORIZONTAL);
@@ -109,7 +109,7 @@
public String getName()
{
- return "Working Directory";
+ return ProcessorMessages.WorkingDirectoryBlock_3;
}
public void initializeFrom(ILaunchConfiguration configuration)
@@ -128,7 +128,7 @@
resourceText.setEnabled(!useDefault);
if (useDefault)
- outputFile = "";
+ outputFile = ""; //$NON-NLS-1$
updateResourceText(useDefault);
}
@@ -168,13 +168,13 @@
catch (CoreException ce)
{
}
- defaultWorkingDir = System.getProperty("user.dir");
+ defaultWorkingDir = System.getProperty("user.dir"); //$NON-NLS-1$
}
private Path getPath(String inputFile)
{
Path path = null;
- if (inputFile.indexOf("${") >= 0)
+ if (inputFile.indexOf("${") >= 0) //$NON-NLS-1$
{
IStringVariableManager manager = VariablesPlugin.getDefault().getStringVariableManager();
try
diff --git a/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/tabs/resolver/messages.properties b/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/tabs/resolver/messages.properties
new file mode 100644
index 0000000..ee85c38
--- /dev/null
+++ b/bundles/org.eclipse.wst.xsl.debug.ui/src/org/eclipse/wst/xsl/internal/debug/ui/tabs/resolver/messages.properties
@@ -0,0 +1,8 @@
+URIResolverBlock2.0=N/A
+URIResolverBlock2.1=Working Directory (default)
+URIResolverBlock2.3=Stylesheet
+URIResolverBlock2.4=Resolve relative to:
+URIResolverBlock2.5=Use custom URI resolver (Note: class must be included on classpath)
+URIResolverBlock2.6=Class:
+URIResolverBlock2.7=URI Resolver
+URIResolverBlock2.8=Missing URI Resolver class name
diff --git a/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/internal/launching/DebuggerDescriptor.java b/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/internal/launching/DebuggerDescriptor.java
index 54b481e..59c6dd9 100644
--- a/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/internal/launching/DebuggerDescriptor.java
+++ b/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/internal/launching/DebuggerDescriptor.java
@@ -50,10 +50,10 @@
{
// in dev, add the bin dir
if (Platform.inDevelopmentMode())
- entries.add(Utils.getFileLocation(bundleId, "/bin"));
+ entries.add(Utils.getFileLocation(bundleId, "/bin")); //$NON-NLS-1$
for (String jar : classpath)
{
- String entry = Utils.getFileLocation(bundleId, "/" + jar);
+ String entry = Utils.getFileLocation(bundleId, "/" + jar); //$NON-NLS-1$
if (entry!=null)
entries.add(entry);
}
diff --git a/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/internal/launching/Feature.java b/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/internal/launching/Feature.java
index 9f812af..266900b 100644
--- a/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/internal/launching/Feature.java
+++ b/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/internal/launching/Feature.java
@@ -48,9 +48,9 @@
IStatus status = null;
if (TYPE_BOOLEAN.equals(type))
{
- boolean valid = "true".equals(value) || "false".equals(value);
+ boolean valid = "true".equals(value) || "false".equals(value); //$NON-NLS-1$ //$NON-NLS-2$
if (!valid)
- status = new Status(IStatus.ERROR, LaunchingPlugin.PLUGIN_ID, 0, "Valid values are 'true' or 'false'", null);
+ status = new Status(IStatus.ERROR, LaunchingPlugin.PLUGIN_ID, 0, Messages.getString("Feature.2"), null); //$NON-NLS-1$
}
else if (TYPE_INT.equals(type))
{
@@ -60,7 +60,7 @@
}
catch (NumberFormatException e)
{
- status = new Status(IStatus.ERROR, LaunchingPlugin.PLUGIN_ID, 0, "Value must be an integer", null);
+ status = new Status(IStatus.ERROR, LaunchingPlugin.PLUGIN_ID, 0, Messages.getString("Feature.1"), null); //$NON-NLS-1$
}
}
else if (TYPE_DOUBLE.equals(type))
@@ -71,7 +71,7 @@
}
catch (NumberFormatException e)
{
- status = new Status(IStatus.ERROR, LaunchingPlugin.PLUGIN_ID, 0, "Value must be a double", null);
+ status = new Status(IStatus.ERROR, LaunchingPlugin.PLUGIN_ID, 0, Messages.getString("Feature.0"), null); //$NON-NLS-1$
}
}
else if (TYPE_FLOAT.equals(type))
@@ -82,7 +82,7 @@
}
catch (NumberFormatException e)
{
- status = new Status(IStatus.ERROR, LaunchingPlugin.PLUGIN_ID, 0, "Value must be a float", null);
+ status = new Status(IStatus.ERROR, LaunchingPlugin.PLUGIN_ID, 0, Messages.getString("Feature.5"), null); //$NON-NLS-1$
}
}
else if (TYPE_CLASS.equals(type) || TYPE_OBJECT.equals(type))
diff --git a/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/internal/launching/FeaturePreferences.java b/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/internal/launching/FeaturePreferences.java
index 683d2ce..8bacde7 100644
--- a/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/internal/launching/FeaturePreferences.java
+++ b/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/internal/launching/FeaturePreferences.java
@@ -39,7 +39,7 @@
public String getAsXML() throws ParserConfigurationException, IOException, TransformerException
{
Document doc = PreferenceUtil.getDocument();
- Element config = doc.createElement("featurePreferences");
+ Element config = doc.createElement("featurePreferences"); //$NON-NLS-1$
doc.appendChild(config);
for (String typeId : typeFeatures.keySet())
@@ -63,7 +63,7 @@
Element config = doc.getDocumentElement();
Map<String, Map<String, String>> typeFeatures = new HashMap<String, Map<String, String>>();
- Element[] processorTypeEls = PreferenceUtil.getChildElements(config, "processorType");
+ Element[] processorTypeEls = PreferenceUtil.getChildElements(config, "processorType"); //$NON-NLS-1$
for (int i = 0; i < processorTypeEls.length; ++i)
{
Element processorTypeEl = processorTypeEls[i];
@@ -79,25 +79,25 @@
private static String elementAsType(Element parent)
{
- String id = parent.getAttribute("id");
+ String id = parent.getAttribute("id"); //$NON-NLS-1$
return id;
}
private static Element typeAsElement(Document doc, String type)
{
- Element element = doc.createElement("processorType");
- element.setAttribute("id", type);
+ Element element = doc.createElement("processorType"); //$NON-NLS-1$
+ element.setAttribute("id", type); //$NON-NLS-1$
return element;
}
private static Map<String, String> elementAsFeatureValues(Element element)
{
- Element[] featureEls = PreferenceUtil.getChildElements(element, "feature");
+ Element[] featureEls = PreferenceUtil.getChildElements(element, "feature"); //$NON-NLS-1$
Map<String, String> featureValues = new HashMap<String, String>(featureEls.length);
for (Element featureEl : featureEls)
{
- String uri = featureEl.getAttribute("uri");
- String value = featureEl.getAttribute("value");
+ String uri = featureEl.getAttribute("uri"); //$NON-NLS-1$
+ String value = featureEl.getAttribute("value"); //$NON-NLS-1$
featureValues.put(uri, value);
}
return featureValues;
@@ -111,9 +111,9 @@
{
String uri = (String) entry2.getKey();
String value = (String) entry2.getValue();
- Element element = doc.createElement("feature");
- element.setAttribute("uri", uri);
- element.setAttribute("value", value);
+ Element element = doc.createElement("feature"); //$NON-NLS-1$
+ element.setAttribute("uri", uri); //$NON-NLS-1$
+ element.setAttribute("value", value); //$NON-NLS-1$
featuresEl.appendChild(element);
}
}
diff --git a/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/internal/launching/LaunchingPlugin.java b/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/internal/launching/LaunchingPlugin.java
index 70ce815..d8abb17 100644
--- a/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/internal/launching/LaunchingPlugin.java
+++ b/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/internal/launching/LaunchingPlugin.java
@@ -23,7 +23,7 @@
{
// The plug-in ID
- public static final String PLUGIN_ID = "org.eclipse.wst.xsl.launching";
+ public static final String PLUGIN_ID = "org.eclipse.wst.xsl.launching"; //$NON-NLS-1$
// The shared instance
private static LaunchingPlugin plugin;
@@ -61,7 +61,7 @@
public static void log(Exception e)
{
- getDefault().getLog().log(new Status(IStatus.ERROR, PLUGIN_ID, 0, "", e));
+ getDefault().getLog().log(new Status(IStatus.ERROR, PLUGIN_ID, 0, "", e)); //$NON-NLS-1$
}
public static void log(CoreException e)
diff --git a/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/internal/launching/Messages.java b/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/internal/launching/Messages.java
new file mode 100644
index 0000000..f153824
--- /dev/null
+++ b/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/internal/launching/Messages.java
@@ -0,0 +1,22 @@
+package org.eclipse.wst.xsl.internal.launching;
+
+import java.util.MissingResourceException;
+import java.util.ResourceBundle;
+
+public class Messages {
+ private static final String BUNDLE_NAME = "org.eclipse.wst.xsl.internal.launching.messages"; //$NON-NLS-1$
+
+ private static final ResourceBundle RESOURCE_BUNDLE = ResourceBundle
+ .getBundle(BUNDLE_NAME);
+
+ private Messages() {
+ }
+
+ public static String getString(String key) {
+ try {
+ return RESOURCE_BUNDLE.getString(key);
+ } catch (MissingResourceException e) {
+ return '!' + key + '!';
+ }
+ }
+}
diff --git a/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/internal/launching/OutputPropertyPreferences.java b/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/internal/launching/OutputPropertyPreferences.java
index c516fa8..e8b919f 100644
--- a/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/internal/launching/OutputPropertyPreferences.java
+++ b/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/internal/launching/OutputPropertyPreferences.java
@@ -40,7 +40,7 @@
public String getAsXML() throws ParserConfigurationException, IOException, TransformerException
{
Document doc = PreferenceUtil.getDocument();
- Element config = doc.createElement("outputPropertyPreferences");
+ Element config = doc.createElement("outputPropertyPreferences"); //$NON-NLS-1$
doc.appendChild(config);
for (String type : typeProperties.keySet())
@@ -63,7 +63,7 @@
Document doc = PreferenceUtil.getDocument(inputStream);
Element config = doc.getDocumentElement();
- Element[] processorTypeEls = PreferenceUtil.getChildElements(config, "processorType");
+ Element[] processorTypeEls = PreferenceUtil.getChildElements(config, "processorType"); //$NON-NLS-1$
for (int i = 0; i < processorTypeEls.length; ++i)
{
Element processorTypeEl = processorTypeEls[i];
@@ -77,25 +77,25 @@
private static String elementAsType(Element parent)
{
- String id = parent.getAttribute("id");
+ String id = parent.getAttribute("id"); //$NON-NLS-1$
return id;
}
private static Element typeAsElement(Document doc, String type)
{
- Element element = doc.createElement("processorType");
- element.setAttribute("id", type);
+ Element element = doc.createElement("processorType"); //$NON-NLS-1$
+ element.setAttribute("id", type); //$NON-NLS-1$
return element;
}
private static Properties elementAsPropertyValues(Element element)
{
- Element[] propertyEls = PreferenceUtil.getChildElements(element, "property");
+ Element[] propertyEls = PreferenceUtil.getChildElements(element, "property"); //$NON-NLS-1$
Properties propertyValues = new Properties();
for (Element featureEl : propertyEls)
{
- String name = featureEl.getAttribute("name");
- String value = featureEl.getAttribute("value");
+ String name = featureEl.getAttribute("name"); //$NON-NLS-1$
+ String value = featureEl.getAttribute("value"); //$NON-NLS-1$
propertyValues.put(name, value);
}
return propertyValues;
@@ -109,9 +109,9 @@
{
String name = (String) entry2.getKey();
String value = (String) entry2.getValue();
- Element element = doc.createElement("property");
- element.setAttribute("name", name);
- element.setAttribute("value", value);
+ Element element = doc.createElement("property"); //$NON-NLS-1$
+ element.setAttribute("name", name); //$NON-NLS-1$
+ element.setAttribute("value", value); //$NON-NLS-1$
featuresEl.appendChild(element);
}
}
diff --git a/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/internal/launching/PluginProcessorJar.java b/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/internal/launching/PluginProcessorJar.java
index 0bb31cf..da8751b 100644
--- a/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/internal/launching/PluginProcessorJar.java
+++ b/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/internal/launching/PluginProcessorJar.java
@@ -42,10 +42,10 @@
// There is surely a better way, but I can'd find it.
if (path == null)
{
- url = Platform.getBundle(pluginId).getEntry("/");
+ url = Platform.getBundle(pluginId).getEntry("/"); //$NON-NLS-1$
url = FileLocator.resolve(url);
String s = url.getPath();
- if (s.endsWith("!/"))
+ if (s.endsWith("!/")) //$NON-NLS-1$
{
s = s.substring(0,s.length()-2);
}
@@ -55,7 +55,7 @@
else
{
Bundle bundle = Platform.getBundle(pluginId);
- IPath jarPath = new Path("/" + path);
+ IPath jarPath = new Path("/" + path); //$NON-NLS-1$
url = FileLocator.find(bundle, jarPath, null);
if (url != null)
url = FileLocator.resolve(url);
@@ -76,6 +76,6 @@
@Override
public String toString()
{
- return "Plugin " + pluginId + ", path " + path;
+ return "Plugin " + pluginId + Messages.getString("PluginProcessorJar.0") + path; //$NON-NLS-1$ //$NON-NLS-2$
}
}
diff --git a/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/internal/launching/PreferenceInitializer.java b/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/internal/launching/PreferenceInitializer.java
index 5cc507e..2e9753c 100644
--- a/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/internal/launching/PreferenceInitializer.java
+++ b/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/internal/launching/PreferenceInitializer.java
@@ -48,7 +48,7 @@
xml = outputPrefs.getAsXML();
node.put(XSLTRuntime.PREF_OUTPUT_PROPERTIES_XML, xml);
- node.put(XSLLaunchConfigurationConstants.ATTR_DEFAULT_DEBUGGING_INSTALL_ID, "org.eclipse.wst.xsl.launching.xalan.2_7_0");
+ node.put(XSLLaunchConfigurationConstants.ATTR_DEFAULT_DEBUGGING_INSTALL_ID, "org.eclipse.wst.xsl.launching.xalan.2_7_0"); //$NON-NLS-1$
}
catch (ParserConfigurationException e)
{
diff --git a/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/internal/launching/PreferenceUtil.java b/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/internal/launching/PreferenceUtil.java
index c7f1ba1..a12c152 100644
--- a/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/internal/launching/PreferenceUtil.java
+++ b/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/internal/launching/PreferenceUtil.java
@@ -60,14 +60,14 @@
TransformerFactory factory = TransformerFactory.newInstance();
Transformer transformer = factory.newTransformer();
- transformer.setOutputProperty(OutputKeys.METHOD, "xml");
- transformer.setOutputProperty(OutputKeys.INDENT, "yes");
+ transformer.setOutputProperty(OutputKeys.METHOD, "xml"); //$NON-NLS-1$
+ transformer.setOutputProperty(OutputKeys.INDENT, "yes"); //$NON-NLS-1$
DOMSource source = new DOMSource(doc);
StreamResult outputTarget = new StreamResult(s);
transformer.transform(source, outputTarget);
- return s.toString("UTF8");
+ return s.toString("UTF8"); //$NON-NLS-1$
}
public static Element[] getChildElements(Element parent, String name)
diff --git a/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/internal/launching/ProcessorInvokerDescriptor.java b/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/internal/launching/ProcessorInvokerDescriptor.java
index 97f30bc..44e0d65 100644
--- a/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/internal/launching/ProcessorInvokerDescriptor.java
+++ b/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/internal/launching/ProcessorInvokerDescriptor.java
@@ -39,16 +39,16 @@
try {
// if in dev mode, use the bin dir
if (Platform.inDevelopmentMode())
- entries.add(Utils.getFileLocation(bundleId, "/bin"));
+ entries.add(Utils.getFileLocation(bundleId, "/bin")); //$NON-NLS-1$
for (int i=0;i <classpath.length;i++)
{
String string = classpath[i];
String entry;
- if (string.startsWith("${eclipse_orbit:") && string.endsWith("}"))
+ if (string.startsWith("${eclipse_orbit:") && string.endsWith("}")) //$NON-NLS-1$ //$NON-NLS-2$
{
- string = string.substring("${eclipse_orbit:".length());
+ string = string.substring("${eclipse_orbit:".length()); //$NON-NLS-1$
string = string.substring(0,string.length()-1);
- entry = Utils.getFileLocation(string,"");
+ entry = Utils.getFileLocation(string,""); //$NON-NLS-1$
}
else
{
diff --git a/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/internal/launching/ProcessorPreferences.java b/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/internal/launching/ProcessorPreferences.java
index 1f9bd1a..413d0ef 100644
--- a/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/internal/launching/ProcessorPreferences.java
+++ b/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/internal/launching/ProcessorPreferences.java
@@ -57,13 +57,13 @@
public String getAsXML() throws ParserConfigurationException, IOException, TransformerException
{
Document doc = PreferenceUtil.getDocument();
- Element config = doc.createElement("processorSettings");
+ Element config = doc.createElement("processorSettings"); //$NON-NLS-1$
doc.appendChild(config);
// Set the defaultVM attribute on the top-level node
if (defaultProcessorId != null)
{
- config.setAttribute("defaultProcessor", defaultProcessorId);
+ config.setAttribute("defaultProcessor", defaultProcessorId); //$NON-NLS-1$
}
for (Iterator<IProcessorInstall> iter = processors.iterator(); iter.hasNext();)
@@ -88,11 +88,11 @@
Element config = doc.getDocumentElement();
// Populate the default VM-related fields
- prefs.setDefaultProcessorId(config.getAttribute("defaultProcessor"));
+ prefs.setDefaultProcessorId(config.getAttribute("defaultProcessor")); //$NON-NLS-1$
List<IProcessorInstall> processors = new ArrayList<IProcessorInstall>();
// Traverse the parsed structure and populate the VMType to VM Map
- Element[] processorEls = PreferenceUtil.getChildElements(config, "processor");
+ Element[] processorEls = PreferenceUtil.getChildElements(config, "processor"); //$NON-NLS-1$
for (int i = 0; i < processorEls.length; ++i)
{
IProcessorInstall processor = elementAsInstall(processorEls[i]);
@@ -106,14 +106,14 @@
private static IProcessorInstall elementAsInstall(Element parent)
{
- String id = parent.getAttribute("id");
- String label = parent.getAttribute("label");
- String typeId = parent.getAttribute("type");
- String supports = parent.getAttribute("supports");
- String debuggerId = parent.getAttribute("debuggerId");
+ String id = parent.getAttribute("id"); //$NON-NLS-1$
+ String label = parent.getAttribute("label"); //$NON-NLS-1$
+ String typeId = parent.getAttribute("type"); //$NON-NLS-1$
+ String supports = parent.getAttribute("supports"); //$NON-NLS-1$
+ String debuggerId = parent.getAttribute("debuggerId"); //$NON-NLS-1$
IProcessorJar[] jars = null;
- Element[] jarsEls = PreferenceUtil.getChildElements(parent, "jars");
+ Element[] jarsEls = PreferenceUtil.getChildElements(parent, "jars"); //$NON-NLS-1$
if (jarsEls.length == 1)
{
jars = elementAsJars(jarsEls[0]);
@@ -124,19 +124,19 @@
private static Element installAsElement(Document doc, IProcessorInstall install)
{
- Element element = doc.createElement("processor");
- element.setAttribute("id", install.getId());
- element.setAttribute("label", install.getName());
- element.setAttribute("type", install.getProcessorType().getId());
- element.setAttribute("supports", install.getSupports());
- element.setAttribute("debuggerId", install.getDebugger() != null ? install.getDebugger().getId() : null);
+ Element element = doc.createElement("processor"); //$NON-NLS-1$
+ element.setAttribute("id", install.getId()); //$NON-NLS-1$
+ element.setAttribute("label", install.getName()); //$NON-NLS-1$
+ element.setAttribute("type", install.getProcessorType().getId()); //$NON-NLS-1$
+ element.setAttribute("supports", install.getSupports()); //$NON-NLS-1$
+ element.setAttribute("debuggerId", install.getDebugger() != null ? install.getDebugger().getId() : null); //$NON-NLS-1$
element.appendChild(jarsAsElement(doc, install.getProcessorJars()));
return element;
}
private static IProcessorJar[] elementAsJars(Element element)
{
- Element[] jarEls = PreferenceUtil.getChildElements(element, "jar");
+ Element[] jarEls = PreferenceUtil.getChildElements(element, "jar"); //$NON-NLS-1$
List<ProcessorJar> jars = new ArrayList<ProcessorJar>(jarEls.length);
for (Element jarEl : jarEls)
{
@@ -152,12 +152,12 @@
private static Element jarsAsElement(Document doc, IProcessorJar[] jars)
{
- Element jarsEl = doc.createElement("jars");
+ Element jarsEl = doc.createElement("jars"); //$NON-NLS-1$
for (IProcessorJar jar : jars)
{
if (jar != null && jar.getPath() != null)
{
- Element jarEl = doc.createElement("jar");
+ Element jarEl = doc.createElement("jar"); //$NON-NLS-1$
Text text = doc.createTextNode(jar.getPath().toPortableString());
jarEl.appendChild(text);
jarsEl.appendChild(jarEl);
diff --git a/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/internal/launching/ProcessorType.java b/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/internal/launching/ProcessorType.java
index cccba25..6f289bd 100644
--- a/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/internal/launching/ProcessorType.java
+++ b/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/internal/launching/ProcessorType.java
@@ -29,8 +29,8 @@
public class ProcessorType implements IProcessorType
{
- private static final String DESC_SUFFIX = ".DESC";
- private static final String TYPE_SUFFIX = ".TYPE";
+ private static final String DESC_SUFFIX = ".DESC"; //$NON-NLS-1$
+ private static final String TYPE_SUFFIX = ".TYPE"; //$NON-NLS-1$
private final String id;
private final String name;
@@ -133,8 +133,8 @@
}
else
{
- LaunchingPlugin.log(new CoreException(new Status(IStatus.WARNING, LaunchingPlugin.PLUGIN_ID, "Output properties file " + outputPropertiesURL
- + " not configured properly for key " + key)));
+ LaunchingPlugin.log(new CoreException(new Status(IStatus.WARNING, LaunchingPlugin.PLUGIN_ID, Messages.getString("ProcessorType.2") + outputPropertiesURL //$NON-NLS-1$
+ + Messages.getString("ProcessorType.3") + key))); //$NON-NLS-1$
}
}
}
@@ -185,8 +185,8 @@
}
else
{
- LaunchingPlugin.log(new CoreException(new Status(IStatus.WARNING, LaunchingPlugin.PLUGIN_ID, "Feature properties file " + featurePropertiesURL
- + " not configured properly for key " + key)));
+ LaunchingPlugin.log(new CoreException(new Status(IStatus.WARNING, LaunchingPlugin.PLUGIN_ID, Messages.getString("ProcessorType.4") + featurePropertiesURL //$NON-NLS-1$
+ + Messages.getString("ProcessorType.5") + key))); //$NON-NLS-1$
}
}
}
diff --git a/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/internal/launching/Utils.java b/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/internal/launching/Utils.java
index 85f8130..11c649a 100644
--- a/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/internal/launching/Utils.java
+++ b/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/internal/launching/Utils.java
@@ -29,7 +29,7 @@
}
catch (IOException e)
{
- throw new CoreException(new Status(IStatus.ERROR, LaunchingPlugin.PLUGIN_ID, IStatus.ERROR, "Error determining jar file location: " + path + " from bundle: " + bundleId, e));
+ throw new CoreException(new Status(IStatus.ERROR, LaunchingPlugin.PLUGIN_ID, IStatus.ERROR, Messages.getString("Utils.0") + path + Messages.getString("Utils.1") + bundleId, e)); //$NON-NLS-1$ //$NON-NLS-2$
}
return location;
}
diff --git a/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/internal/launching/XSLTLaunchConfigurationDelegate.java b/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/internal/launching/XSLTLaunchConfigurationDelegate.java
index 1e13510..8739d75 100644
--- a/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/internal/launching/XSLTLaunchConfigurationDelegate.java
+++ b/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/internal/launching/XSLTLaunchConfigurationDelegate.java
@@ -217,8 +217,8 @@
IProcessorInstall processor = XSLTRuntime.getProcessor(debuggingInstallId);
IWorkbenchWindow dw = PlatformUI.getWorkbench().getActiveWorkbenchWindow();
- result[0] = MessageDialog.openQuestion(dw.getShell(), "XSLT Processor Debugger", "The " + install.getName() + " XSLT processor does not support debugging.\n"
- + "Would you like to debug using the default " + processor.getName() + " processor instead?");
+ result[0] = MessageDialog.openQuestion(dw.getShell(), Messages.getString("XSLTLaunchConfigurationDelegate.0"), Messages.getString("XSLTLaunchConfigurationDelegate.1") + install.getName() + Messages.getString("XSLTLaunchConfigurationDelegate.2") //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
+ + Messages.getString("XSLTLaunchConfigurationDelegate.3") + processor.getName() + Messages.getString("XSLTLaunchConfigurationDelegate.4")); //$NON-NLS-1$ //$NON-NLS-2$
}
});
return result[0];
@@ -238,11 +238,11 @@
private File getLaunchConfigFile()
{
- IPath launchPath = Platform.getStateLocation(LaunchingPlugin.getDefault().getBundle()).append("launch");
+ IPath launchPath = Platform.getStateLocation(LaunchingPlugin.getDefault().getBundle()).append(Messages.getString("XSLTLaunchConfigurationDelegate.5")); //$NON-NLS-1$
File launchDir = launchPath.toFile();
if (!launchDir.exists())
launchDir.mkdir();
- File featuresFile = new File(launchDir, "launch.xml");
+ File featuresFile = new File(launchDir, Messages.getString("XSLTLaunchConfigurationDelegate.6")); //$NON-NLS-1$
return featuresFile;
}
@@ -262,7 +262,7 @@
{
String invokerId = configuration.getAttribute(XSLLaunchConfigurationConstants.INVOKER_DESCRIPTOR, (String) null);
if (invokerId == null)
- invokerId = "org.eclipse.wst.xsl.launching.jaxp.invoke";
+ invokerId = "org.eclipse.wst.xsl.launching.jaxp.invoke"; //$NON-NLS-1$
return XSLTRuntime.getProcessorInvoker(invokerId);
}
@@ -276,7 +276,7 @@
}
else
{
- String processorId = configuration.getAttribute(XSLLaunchConfigurationConstants.ATTR_PROCESSOR, "");
+ String processorId = configuration.getAttribute(XSLLaunchConfigurationConstants.ATTR_PROCESSOR, ""); //$NON-NLS-1$
install = XSLTRuntime.getProcessor(processorId);
}
if (mode.equals(ILaunchManager.DEBUG_MODE) && install.getDebugger() == null)
@@ -291,8 +291,8 @@
public String getMainTypeName(ILaunchConfiguration configuration) throws CoreException
{
if (ILaunchManager.DEBUG_MODE.equals(mode))
- return "org.eclipse.wst.xsl.debugger.DebugRunner";
- return "org.eclipse.wst.xsl.invoker.Main";
+ return "org.eclipse.wst.xsl.debugger.DebugRunner"; //$NON-NLS-1$
+ return "org.eclipse.wst.xsl.invoker.Main"; //$NON-NLS-1$
}
@Override
@@ -304,12 +304,12 @@
StringBuffer sb = new StringBuffer();
sb.append(clazz);
- sb.append(" ");
- sb.append("\"" + getLaunchConfigFile().getAbsolutePath() + "\"");
- sb.append(" ");
- sb.append("\"" + launchHelper.getSource() + "\"");
- sb.append(" ");
- sb.append("\"" + launchHelper.getTarget().getAbsolutePath() + "\"");
+ sb.append(" "); //$NON-NLS-1$
+ sb.append("\"" + getLaunchConfigFile().getAbsolutePath() + "\""); //$NON-NLS-1$ //$NON-NLS-2$
+ sb.append(" "); //$NON-NLS-1$
+ sb.append("\"" + launchHelper.getSource() + "\""); //$NON-NLS-1$ //$NON-NLS-2$
+ sb.append(" "); //$NON-NLS-1$
+ sb.append("\"" + launchHelper.getTarget().getAbsolutePath() + "\""); //$NON-NLS-1$ //$NON-NLS-2$
if (ILaunchManager.DEBUG_MODE.equals(mode))
{
IProcessorInstall install = getProcessorInstall(configuration, mode);
@@ -317,8 +317,8 @@
{
IDebugger debugger = install.getDebugger();
String className = debugger.getClassName();
- sb.append(" -debug ").append(className).append(" ");
- sb.append(launchHelper.getRequestPort()).append(" ").append(launchHelper.getEventPort());
+ sb.append(" -debug ").append(className).append(" "); //$NON-NLS-1$ //$NON-NLS-2$
+ sb.append(launchHelper.getRequestPort()).append(" ").append(launchHelper.getEventPort()); //$NON-NLS-1$
}
}
@@ -387,22 +387,22 @@
{
URL entry = jars[i].asURL();
if (entry == null)
- throw new CoreException(new Status(IStatus.ERROR, LaunchingPlugin.PLUGIN_ID, IStatus.ERROR, "Could not locate jar file " + jars[i], null));
- File file = new File(tempDir, "END_" + i + ".jar");
+ throw new CoreException(new Status(IStatus.ERROR, LaunchingPlugin.PLUGIN_ID, IStatus.ERROR, Messages.getString("XSLTLaunchConfigurationDelegate.23") + jars[i], null)); //$NON-NLS-1$
+ File file = new File(tempDir, "END_" + i + ".jar"); //$NON-NLS-1$ //$NON-NLS-2$
moveFile(entry, file);
}
// add the endorsed dir
- vmargs += " -Djava.endorsed.dirs=\"" + tempDir.getAbsolutePath() + "\"";
+ vmargs += " -Djava.endorsed.dirs=\"" + tempDir.getAbsolutePath() + "\""; //$NON-NLS-1$ //$NON-NLS-2$
String tfactory = install.getProcessorType().getTransformerFactoryName();
if (tfactory != null)
- vmargs += " -Djavax.xml.transform.TransformerFactory=" + install.getProcessorType().getTransformerFactoryName();
+ vmargs += " -Djavax.xml.transform.TransformerFactory=" + install.getProcessorType().getTransformerFactoryName(); //$NON-NLS-1$
}
return vmargs;
}
private File getEndorsedDir()
{
- IPath tempLocation = Platform.getStateLocation(LaunchingPlugin.getDefault().getBundle()).append("endorsed");
+ IPath tempLocation = Platform.getStateLocation(LaunchingPlugin.getDefault().getBundle()).append("endorsed"); //$NON-NLS-1$
return tempLocation.toFile();
}
@@ -426,7 +426,7 @@
}
catch (IOException e)
{
- throw new CoreException(new Status(IStatus.ERROR, LaunchingPlugin.PLUGIN_ID, IStatus.ERROR, "Error copying url " + src + " to " + target, e));
+ throw new CoreException(new Status(IStatus.ERROR, LaunchingPlugin.PLUGIN_ID, IStatus.ERROR, Messages.getString("XSLTLaunchConfigurationDelegate.7") + src + Messages.getString("XSLTLaunchConfigurationDelegate.31") + target, e)); //$NON-NLS-1$ //$NON-NLS-2$
}
finally
{
diff --git a/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/internal/launching/messages.properties b/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/internal/launching/messages.properties
new file mode 100644
index 0000000..ff3cdbd
--- /dev/null
+++ b/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/internal/launching/messages.properties
@@ -0,0 +1,21 @@
+Feature.0=Value must be a double
+Feature.1=Value must be an integer
+Feature.2=Valid values are 'true' or 'false'
+Feature.5=Value must be a float
+PluginProcessorJar.0=, path
+ProcessorType.2=Output properties file
+ProcessorType.3=\ not configured properly for key
+ProcessorType.4=Feature properties file
+ProcessorType.5=\ not configured properly for key
+Utils.0=Error determining jar file location:
+Utils.1=\ from bundle:
+XSLTLaunchConfigurationDelegate.0=XSLT Processor Debugger
+XSLTLaunchConfigurationDelegate.1=The
+XSLTLaunchConfigurationDelegate.2=\ XSLT processor does not support debugging.\n
+XSLTLaunchConfigurationDelegate.23=Could not locate jar file
+XSLTLaunchConfigurationDelegate.3=Would you like to debug using the default
+XSLTLaunchConfigurationDelegate.31=\ to
+XSLTLaunchConfigurationDelegate.4=\ processor instead?
+XSLTLaunchConfigurationDelegate.5=launch
+XSLTLaunchConfigurationDelegate.6=launch.xml
+XSLTLaunchConfigurationDelegate.7=Error copying url
diff --git a/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/internal/launching/registry/AbstractRegistryReader.java b/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/internal/launching/registry/AbstractRegistryReader.java
index 99076c2..d799c57 100644
--- a/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/internal/launching/registry/AbstractRegistryReader.java
+++ b/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/internal/launching/registry/AbstractRegistryReader.java
@@ -25,31 +25,31 @@
public abstract class AbstractRegistryReader
{
- public static final String ATT_CLASS = "class";
- public static final String TAG_DESCRIPTION = "description";
+ public static final String ATT_CLASS = "class"; //$NON-NLS-1$
+ public static final String TAG_DESCRIPTION = "description"; //$NON-NLS-1$
protected static void logError(IConfigurationElement element, String text)
{
IExtension extension = element.getDeclaringExtension();
StringBuffer buf = new StringBuffer();
- buf.append("Plugin " + extension.getNamespaceIdentifier() + ", extension " + extension.getExtensionPointUniqueIdentifier());
- buf.append("\n" + text);
+ buf.append("Plugin " + extension.getNamespaceIdentifier() + Messages.getString("AbstractRegistryReader.3") + extension.getExtensionPointUniqueIdentifier()); //$NON-NLS-1$ //$NON-NLS-2$
+ buf.append("\n" + text); //$NON-NLS-1$
LaunchingPlugin.log(new CoreException(new Status(IStatus.ERROR, LaunchingPlugin.PLUGIN_ID, IStatus.OK, buf.toString(), null)));
}
protected static void logMissingAttribute(IConfigurationElement element, String attributeName)
{
- logError(element, "Required attribute '" + attributeName + "' not defined");
+ logError(element, Messages.getString("AbstractRegistryReader.5") + attributeName + Messages.getString("AbstractRegistryReader.6")); //$NON-NLS-1$ //$NON-NLS-2$
}
protected static void logMissingElement(IConfigurationElement element, String elementName)
{
- logError(element, "Required sub element '" + elementName + "' not defined");
+ logError(element, Messages.getString("AbstractRegistryReader.7") + elementName + Messages.getString("AbstractRegistryReader.8")); //$NON-NLS-1$ //$NON-NLS-2$
}
protected static void logUnknownElement(IConfigurationElement element)
{
- logError(element, "Unknown extension tag found: " + element.getName());
+ logError(element, Messages.getString("AbstractRegistryReader.9") + element.getName()); //$NON-NLS-1$
}
public static IExtension[] orderExtensions(IExtension[] extensions)
@@ -108,7 +108,7 @@
{
return children[0].getValue();
}
- return "";
+ return ""; //$NON-NLS-1$
}
public static String getClassValue(IConfigurationElement configElement, String classAttributeName)
diff --git a/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/internal/launching/registry/DebuggerRegistryReader.java b/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/internal/launching/registry/DebuggerRegistryReader.java
index c2d0cc3..b5da573 100644
--- a/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/internal/launching/registry/DebuggerRegistryReader.java
+++ b/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/internal/launching/registry/DebuggerRegistryReader.java
@@ -18,12 +18,12 @@
public class DebuggerRegistryReader extends AbstractRegistryReader
{
- public static final String TAG_DEBUGGER = "debugger";
- public static final String ATT_ID = "id";
- public static final String ATT_CLASSNAME = "className";
- public static final String ATT_CLASSPATH = "classpath";
- public static final String ATT_NAME = "name";
- public static final String ATT_PROCESSOR_TYPE_ID = "processorTypeId";
+ public static final String TAG_DEBUGGER = "debugger"; //$NON-NLS-1$
+ public static final String ATT_ID = "id"; //$NON-NLS-1$
+ public static final String ATT_CLASSNAME = "className"; //$NON-NLS-1$
+ public static final String ATT_CLASSPATH = "classpath"; //$NON-NLS-1$
+ public static final String ATT_NAME = "name"; //$NON-NLS-1$
+ public static final String ATT_PROCESSOR_TYPE_ID = "processorTypeId"; //$NON-NLS-1$
private DebuggerRegistry registry;
@@ -54,7 +54,7 @@
return true;
}
- String[] entries = classpath.split(";");
+ String[] entries = classpath.split(";"); //$NON-NLS-1$
for (int i = 0; i < entries.length; i++)
{
String string = entries[i];
@@ -90,6 +90,6 @@
{
IExtensionRegistry extensionRegistry = Platform.getExtensionRegistry();
this.registry = registry;
- readRegistry(extensionRegistry, LaunchingPlugin.PLUGIN_ID, "debugger");
+ readRegistry(extensionRegistry, LaunchingPlugin.PLUGIN_ID, "debugger"); //$NON-NLS-1$
}
}
diff --git a/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/internal/launching/registry/InvokerRegistryReader.java b/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/internal/launching/registry/InvokerRegistryReader.java
index 21481b2..8a52471 100644
--- a/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/internal/launching/registry/InvokerRegistryReader.java
+++ b/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/internal/launching/registry/InvokerRegistryReader.java
@@ -18,10 +18,10 @@
public class InvokerRegistryReader extends AbstractRegistryReader
{
- public static final String TAG_INVOKE = "invoker";
- public static final String ATT_ID = "id";
- public static final String ATT_CLASS = "class";
- public static final String ATT_CLASSPATH = "classpath";
+ public static final String TAG_INVOKE = "invoker"; //$NON-NLS-1$
+ public static final String ATT_ID = "id"; //$NON-NLS-1$
+ public static final String ATT_CLASS = "class"; //$NON-NLS-1$
+ public static final String ATT_CLASSPATH = "classpath"; //$NON-NLS-1$
private InvokerRegistry registry;
@@ -52,7 +52,7 @@
return true;
}
- String[] entries = classpath.split(";");
+ String[] entries = classpath.split(";"); //$NON-NLS-1$
for (int i = 0; i < entries.length; i++)
{
String string = entries[i];
@@ -74,6 +74,6 @@
{
IExtensionRegistry extensionRegistry = Platform.getExtensionRegistry();
this.registry = registry;
- readRegistry(extensionRegistry, LaunchingPlugin.PLUGIN_ID, "invoke");
+ readRegistry(extensionRegistry, LaunchingPlugin.PLUGIN_ID, "invoke"); //$NON-NLS-1$
}
}
diff --git a/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/internal/launching/registry/Messages.java b/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/internal/launching/registry/Messages.java
new file mode 100644
index 0000000..fb017f0
--- /dev/null
+++ b/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/internal/launching/registry/Messages.java
@@ -0,0 +1,22 @@
+package org.eclipse.wst.xsl.internal.launching.registry;
+
+import java.util.MissingResourceException;
+import java.util.ResourceBundle;
+
+public class Messages {
+ private static final String BUNDLE_NAME = "org.eclipse.wst.xsl.internal.launching.registry.messages"; //$NON-NLS-1$
+
+ private static final ResourceBundle RESOURCE_BUNDLE = ResourceBundle
+ .getBundle(BUNDLE_NAME);
+
+ private Messages() {
+ }
+
+ public static String getString(String key) {
+ try {
+ return RESOURCE_BUNDLE.getString(key);
+ } catch (MissingResourceException e) {
+ return '!' + key + '!';
+ }
+ }
+}
diff --git a/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/internal/launching/registry/ProcessorRegistryReader.java b/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/internal/launching/registry/ProcessorRegistryReader.java
index 67ada8a..7187571 100644
--- a/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/internal/launching/registry/ProcessorRegistryReader.java
+++ b/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/internal/launching/registry/ProcessorRegistryReader.java
@@ -17,13 +17,13 @@
public class ProcessorRegistryReader extends AbstractRegistryReader
{
- public static final String TAG_processor = "processor";
- public static final String ATT_ID = "id";
- public static final String ATT_LABEL = "label";
- public static final String ATT_TYPE_ID = "processorTypeId";
- public static final String ATT_DEBUGGER_ID = "debuggerId";
- public static final String ATT_CLASSPATH = "classpath";
- public static final String ATT_SUPPORTS = "supports";
+ public static final String TAG_processor = "processor"; //$NON-NLS-1$
+ public static final String ATT_ID = "id"; //$NON-NLS-1$
+ public static final String ATT_LABEL = "label"; //$NON-NLS-1$
+ public static final String ATT_TYPE_ID = "processorTypeId"; //$NON-NLS-1$
+ public static final String ATT_DEBUGGER_ID = "debuggerId"; //$NON-NLS-1$
+ public static final String ATT_CLASSPATH = "classpath"; //$NON-NLS-1$
+ public static final String ATT_SUPPORTS = "supports"; //$NON-NLS-1$
private ProcessorRegistry registry;
@@ -85,6 +85,6 @@
{
IExtensionRegistry extensionRegistry = Platform.getExtensionRegistry();
this.registry = registry;
- readRegistry(extensionRegistry, LaunchingPlugin.PLUGIN_ID, "processor");
+ readRegistry(extensionRegistry, LaunchingPlugin.PLUGIN_ID, "processor"); //$NON-NLS-1$
}
}
diff --git a/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/internal/launching/registry/ProcessorTypeRegistry.java b/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/internal/launching/registry/ProcessorTypeRegistry.java
index d45a694..2e80ad5 100644
--- a/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/internal/launching/registry/ProcessorTypeRegistry.java
+++ b/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/internal/launching/registry/ProcessorTypeRegistry.java
@@ -33,8 +33,8 @@
public class ProcessorTypeRegistry
{
- protected static final String DESC_SUFFIX = ".DESC";
- protected static final String TYPE_SUFFIX = ".TYPE";
+ protected static final String DESC_SUFFIX = ".DESC"; //$NON-NLS-1$
+ protected static final String TYPE_SUFFIX = ".TYPE"; //$NON-NLS-1$
private final List<IConfigurationElement> elements = new ArrayList<IConfigurationElement>();
private IProcessorType[] installTypes;
diff --git a/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/internal/launching/registry/ProcessorTypeRegistryReader.java b/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/internal/launching/registry/ProcessorTypeRegistryReader.java
index 82f767c..9c7f1e0 100644
--- a/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/internal/launching/registry/ProcessorTypeRegistryReader.java
+++ b/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/internal/launching/registry/ProcessorTypeRegistryReader.java
@@ -17,12 +17,12 @@
public class ProcessorTypeRegistryReader extends AbstractRegistryReader
{
- public static final String TAG_processorType = "processorType";
- public static final String ATT_ID = "id";
- public static final String ATT_LABEL = "label";
- public static final String ATT_TRANSFORMER_FACTORY_NAME = "transformerFactory";
- public static final String ATT_OUTPUT_PROPERTIES = "outputProperties";
- public static final String ATT_FEATURE_PROPERTIES = "featureProperties";
+ public static final String TAG_processorType = "processorType"; //$NON-NLS-1$
+ public static final String ATT_ID = "id"; //$NON-NLS-1$
+ public static final String ATT_LABEL = "label"; //$NON-NLS-1$
+ public static final String ATT_TRANSFORMER_FACTORY_NAME = "transformerFactory"; //$NON-NLS-1$
+ public static final String ATT_OUTPUT_PROPERTIES = "outputProperties"; //$NON-NLS-1$
+ public static final String ATT_FEATURE_PROPERTIES = "featureProperties"; //$NON-NLS-1$
private ProcessorTypeRegistry registry;
@@ -75,6 +75,6 @@
{
IExtensionRegistry extensionRegistry = Platform.getExtensionRegistry();
this.registry = registry;
- readRegistry(extensionRegistry, LaunchingPlugin.PLUGIN_ID, "processorType");
+ readRegistry(extensionRegistry, LaunchingPlugin.PLUGIN_ID, "processorType"); //$NON-NLS-1$
}
}
diff --git a/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/internal/launching/registry/messages.properties b/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/internal/launching/registry/messages.properties
new file mode 100644
index 0000000..6a64057
--- /dev/null
+++ b/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/internal/launching/registry/messages.properties
@@ -0,0 +1,6 @@
+AbstractRegistryReader.3=, extension
+AbstractRegistryReader.5=Required attribute '
+AbstractRegistryReader.6=' not defined
+AbstractRegistryReader.7=Required sub element '
+AbstractRegistryReader.8=' not defined
+AbstractRegistryReader.9=Unknown extension tag found:
diff --git a/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/launching/IFeature.java b/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/launching/IFeature.java
index f4d893c..3fff40e 100644
--- a/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/launching/IFeature.java
+++ b/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/launching/IFeature.java
@@ -23,43 +23,43 @@
* Constant for features of type <code>string</code>
* @see #getType()
*/
- String TYPE_STRING = "string";
+ String TYPE_STRING = "string"; //$NON-NLS-1$
/**
* Constant for features of type <code>boolean</code>
* @see #getType()
*/
- String TYPE_BOOLEAN = "boolean";
+ String TYPE_BOOLEAN = "boolean"; //$NON-NLS-1$
/**
* Constant for features of type <code>int</code>
* @see #getType()
*/
- String TYPE_INT = "int";
+ String TYPE_INT = "int"; //$NON-NLS-1$
/**
* Constant for features of type <code>double</code>
* @see #getType()
*/
- String TYPE_DOUBLE = "double";
+ String TYPE_DOUBLE = "double"; //$NON-NLS-1$
/**
* Constant for features of type <code>float</code>
* @see #getType()
*/
- String TYPE_FLOAT = "float";
+ String TYPE_FLOAT = "float"; //$NON-NLS-1$
/**
* Constant for features of type <code>class</code>
* @see #getType()
*/
- String TYPE_CLASS = "class";
+ String TYPE_CLASS = "class"; //$NON-NLS-1$
/**
* Constant for features of type <code>object</code>
* @see #getType()
*/
- String TYPE_OBJECT = "object";
+ String TYPE_OBJECT = "object"; //$NON-NLS-1$
/**
* Get the URI for this feature
diff --git a/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/launching/Messages.java b/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/launching/Messages.java
new file mode 100644
index 0000000..7687483
--- /dev/null
+++ b/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/launching/Messages.java
@@ -0,0 +1,22 @@
+package org.eclipse.wst.xsl.launching;
+
+import java.util.MissingResourceException;
+import java.util.ResourceBundle;
+
+public class Messages {
+ private static final String BUNDLE_NAME = "org.eclipse.wst.xsl.launching.messages"; //$NON-NLS-1$
+
+ private static final ResourceBundle RESOURCE_BUNDLE = ResourceBundle
+ .getBundle(BUNDLE_NAME);
+
+ private Messages() {
+ }
+
+ public static String getString(String key) {
+ try {
+ return RESOURCE_BUNDLE.getString(key);
+ } catch (MissingResourceException e) {
+ return '!' + key + '!';
+ }
+ }
+}
diff --git a/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/launching/ProcessorInstall.java b/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/launching/ProcessorInstall.java
index 873d6c0..755c5f0 100644
--- a/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/launching/ProcessorInstall.java
+++ b/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/launching/ProcessorInstall.java
@@ -88,16 +88,16 @@
IProcessorJar[] jars;
if (classpath == null)
return new IProcessorJar[0];
- String[] jarstring = classpath.split(";");
+ String[] jarstring = classpath.split(";"); //$NON-NLS-1$
jars = new IProcessorJar[jarstring.length];
for (int i = 0; i < jarstring.length; i++)
{
String jar = jarstring[i];
try
{
- if (jar.startsWith("${eclipse_orbit:") && jar.endsWith("}"))
+ if (jar.startsWith("${eclipse_orbit:") && jar.endsWith("}")) //$NON-NLS-1$ //$NON-NLS-2$
{
- jar = jar.substring("${eclipse_orbit:".length());
+ jar = jar.substring("${eclipse_orbit:".length()); //$NON-NLS-1$
jar = jar.substring(0,jar.length()-1);
//jar = Utils.getFileLocation(jar,"");
jars[i] = new PluginProcessorJar(jar, null);
diff --git a/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/launching/XSLLaunchConfigurationConstants.java b/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/launching/XSLLaunchConfigurationConstants.java
index 8530fb2..6c133d6 100644
--- a/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/launching/XSLLaunchConfigurationConstants.java
+++ b/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/launching/XSLLaunchConfigurationConstants.java
@@ -14,32 +14,32 @@
public class XSLLaunchConfigurationConstants
{
- public static final String INVOKER_DESCRIPTOR = LaunchingPlugin.PLUGIN_ID + ".INVOKER_DESCRIPTOR";
- public static final String ATTR_PROCESSOR = LaunchingPlugin.PLUGIN_ID + ".ATTR_PROCESSOR";
- public static final String ATTR_LAUNCH_TYPE = LaunchingPlugin.PLUGIN_ID + ".ATTR_LAUNCH_TYPE";
- public static final String ATTR_BASE_URI_TYPE = LaunchingPlugin.PLUGIN_ID + ".ATTR_BASE_URI_TYPE";
- public static final String ATTR_BASE_URI_DIRECTORY = LaunchingPlugin.PLUGIN_ID + ".ATTR_BASE_URI_DIRECTORY";
- public static final String ATTR_PROJECT_NAME = LaunchingPlugin.PLUGIN_ID + ".ATTR_PROJECT_NAME";
- public static final String ATTR_INPUT_FILE = LaunchingPlugin.PLUGIN_ID + ".ATTR_INPUT_FILE";
- public static final String ATTR_OUTPUT_FILE = LaunchingPlugin.PLUGIN_ID + ".ATTR_OUTPUT_FILE";
- public static final String ATTR_OUTPUT_METHOD = LaunchingPlugin.PLUGIN_ID + ".ATTR_OUTPUT_METHOD";
- public static final String ATTR_OUTPUT_PROPERTIES = LaunchingPlugin.PLUGIN_ID + ".ATTR_OUTPUT_PROPERTIES";
- public static final String ATTR_STYLESHEETS_LIST = LaunchingPlugin.PLUGIN_ID + ".ATTR_STYLESHEETS_LIST";
- public static final String ATTR_RENDER_TO = LaunchingPlugin.PLUGIN_ID + ".ATTR_RENDER_TO";
- public static final String ID_LAUNCH_CONFIG_TYPE = LaunchingPlugin.PLUGIN_ID + ".launchConfigurationType";
- public static final String ATTR_PERFORM_RENDER = LaunchingPlugin.PLUGIN_ID + ".ATTR_PERFORM_RENDER";
- public static final String ATTR_USE_DEFAULT_OUTPUT_FILE = LaunchingPlugin.PLUGIN_ID + ".ATTR_USE_DEFAULT_OUTPUT_FILE";
- public static final String ATTR_OPEN_FILE = LaunchingPlugin.PLUGIN_ID + ".ATTR_OPEN_FILE";
- public static final String ATTR_PROCESSOR_WORKING_DIR = LaunchingPlugin.PLUGIN_ID + ".ATTR_PROCESSOR_WORKING_DIR";
- public static final String ATTR_USE_DEFAULT_PROCESSOR_WORKING_DIR = LaunchingPlugin.PLUGIN_ID + ".ATTR_USE_DEFAULT_PROCESSOR_WORKING_DIR";
- public static final String ATTR_USE_DEFAULT_PROCESSOR = LaunchingPlugin.PLUGIN_ID + ".ATTR_USE_DEFAULT_PROCESSOR";
- public static final String ATTR_USE_FEATURES_FROM_PREFERENCES = LaunchingPlugin.PLUGIN_ID + ".ATTR_USE_FEATURES_FROM_PREFERENCES";
- public static final String ATTR_USE_PROPERTIES_FROM_PREFERENCES = LaunchingPlugin.PLUGIN_ID + ".ATTR_USE_PROPERTIES_FROM_PREFERENCES";
- public static final String ATTR_JRE_DEFAULT_TYPE_TYPE = ".ATTR_JRE_DEFAULT_TYPE_TYPE";
- public static final String ATTR_FEATURES = LaunchingPlugin.PLUGIN_ID + ".ATTR_FEATURES";
- public static final String ATTR_PIPELINE = LaunchingPlugin.PLUGIN_ID + ".ATTR_PIPELINE";
- public static final String ATTR_DEFAULT_DEBUGGING_INSTALL_ID = LaunchingPlugin.PLUGIN_ID + ".ATTR_DEFAULT_DEBUGGING_INSTALL_ID";;
+ public static final String INVOKER_DESCRIPTOR = LaunchingPlugin.PLUGIN_ID + ".INVOKER_DESCRIPTOR"; //$NON-NLS-1$
+ public static final String ATTR_PROCESSOR = LaunchingPlugin.PLUGIN_ID + ".ATTR_PROCESSOR"; //$NON-NLS-1$
+ public static final String ATTR_LAUNCH_TYPE = LaunchingPlugin.PLUGIN_ID + ".ATTR_LAUNCH_TYPE"; //$NON-NLS-1$
+ public static final String ATTR_BASE_URI_TYPE = LaunchingPlugin.PLUGIN_ID + ".ATTR_BASE_URI_TYPE"; //$NON-NLS-1$
+ public static final String ATTR_BASE_URI_DIRECTORY = LaunchingPlugin.PLUGIN_ID + ".ATTR_BASE_URI_DIRECTORY"; //$NON-NLS-1$
+ public static final String ATTR_PROJECT_NAME = LaunchingPlugin.PLUGIN_ID + ".ATTR_PROJECT_NAME"; //$NON-NLS-1$
+ public static final String ATTR_INPUT_FILE = LaunchingPlugin.PLUGIN_ID + ".ATTR_INPUT_FILE"; //$NON-NLS-1$
+ public static final String ATTR_OUTPUT_FILE = LaunchingPlugin.PLUGIN_ID + ".ATTR_OUTPUT_FILE"; //$NON-NLS-1$
+ public static final String ATTR_OUTPUT_METHOD = LaunchingPlugin.PLUGIN_ID + ".ATTR_OUTPUT_METHOD"; //$NON-NLS-1$
+ public static final String ATTR_OUTPUT_PROPERTIES = LaunchingPlugin.PLUGIN_ID + ".ATTR_OUTPUT_PROPERTIES"; //$NON-NLS-1$
+ public static final String ATTR_STYLESHEETS_LIST = LaunchingPlugin.PLUGIN_ID + ".ATTR_STYLESHEETS_LIST"; //$NON-NLS-1$
+ public static final String ATTR_RENDER_TO = LaunchingPlugin.PLUGIN_ID + ".ATTR_RENDER_TO"; //$NON-NLS-1$
+ public static final String ID_LAUNCH_CONFIG_TYPE = LaunchingPlugin.PLUGIN_ID + ".launchConfigurationType"; //$NON-NLS-1$
+ public static final String ATTR_PERFORM_RENDER = LaunchingPlugin.PLUGIN_ID + ".ATTR_PERFORM_RENDER"; //$NON-NLS-1$
+ public static final String ATTR_USE_DEFAULT_OUTPUT_FILE = LaunchingPlugin.PLUGIN_ID + ".ATTR_USE_DEFAULT_OUTPUT_FILE"; //$NON-NLS-1$
+ public static final String ATTR_OPEN_FILE = LaunchingPlugin.PLUGIN_ID + ".ATTR_OPEN_FILE"; //$NON-NLS-1$
+ public static final String ATTR_PROCESSOR_WORKING_DIR = LaunchingPlugin.PLUGIN_ID + ".ATTR_PROCESSOR_WORKING_DIR"; //$NON-NLS-1$
+ public static final String ATTR_USE_DEFAULT_PROCESSOR_WORKING_DIR = LaunchingPlugin.PLUGIN_ID + ".ATTR_USE_DEFAULT_PROCESSOR_WORKING_DIR"; //$NON-NLS-1$
+ public static final String ATTR_USE_DEFAULT_PROCESSOR = LaunchingPlugin.PLUGIN_ID + ".ATTR_USE_DEFAULT_PROCESSOR"; //$NON-NLS-1$
+ public static final String ATTR_USE_FEATURES_FROM_PREFERENCES = LaunchingPlugin.PLUGIN_ID + ".ATTR_USE_FEATURES_FROM_PREFERENCES"; //$NON-NLS-1$
+ public static final String ATTR_USE_PROPERTIES_FROM_PREFERENCES = LaunchingPlugin.PLUGIN_ID + ".ATTR_USE_PROPERTIES_FROM_PREFERENCES"; //$NON-NLS-1$
+ public static final String ATTR_JRE_DEFAULT_TYPE_TYPE = ".ATTR_JRE_DEFAULT_TYPE_TYPE"; //$NON-NLS-1$
+ public static final String ATTR_FEATURES = LaunchingPlugin.PLUGIN_ID + ".ATTR_FEATURES"; //$NON-NLS-1$
+ public static final String ATTR_PIPELINE = LaunchingPlugin.PLUGIN_ID + ".ATTR_PIPELINE"; //$NON-NLS-1$
+ public static final String ATTR_DEFAULT_DEBUGGING_INSTALL_ID = LaunchingPlugin.PLUGIN_ID + ".ATTR_DEFAULT_DEBUGGING_INSTALL_ID";; //$NON-NLS-1$
- public static final String XALAN_TYPE_ID = "org.eclipse.wst.xsl.xalan.processorType";
- public static final String SAXONB_TYPE_ID = "org.eclipse.wst.xsl.saxon.processorType";
+ public static final String XALAN_TYPE_ID = "org.eclipse.wst.xsl.xalan.processorType"; //$NON-NLS-1$
+ public static final String SAXONB_TYPE_ID = "org.eclipse.wst.xsl.saxon.processorType"; //$NON-NLS-1$
}
diff --git a/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/launching/XSLTRuntime.java b/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/launching/XSLTRuntime.java
index 31d9f68..e48fdc2 100644
--- a/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/launching/XSLTRuntime.java
+++ b/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/launching/XSLTRuntime.java
@@ -38,11 +38,11 @@
public class XSLTRuntime
{
- public static final String PREF_PROCESSOR_XML = "PREF_PROCESSOR_XML";
- public static final String PREF_FEATURE_XML = "PREF_FEATURE_XML";
- public static final String PREF_OUTPUT_PROPERTIES_XML = "PREF_OUTPUT_PROPERTIES_XML";
- public static final String JRE_DEFAULT_PROCESSOR_ID = "org.eclipse.wst.xsl.launching.jre.default";
- public static final String JRE_DEFAULT_PROCESSOR_TYPE_ID = "org.eclipse.wst.xsl.launching.processorType.jreDefault";
+ public static final String PREF_PROCESSOR_XML = "PREF_PROCESSOR_XML"; //$NON-NLS-1$
+ public static final String PREF_FEATURE_XML = "PREF_FEATURE_XML"; //$NON-NLS-1$
+ public static final String PREF_OUTPUT_PROPERTIES_XML = "PREF_OUTPUT_PROPERTIES_XML"; //$NON-NLS-1$
+ public static final String JRE_DEFAULT_PROCESSOR_ID = "org.eclipse.wst.xsl.launching.jre.default"; //$NON-NLS-1$
+ public static final String JRE_DEFAULT_PROCESSOR_TYPE_ID = "org.eclipse.wst.xsl.launching.processorType.jreDefault"; //$NON-NLS-1$
private static byte[] NEXT_ID_LOCK = new byte[0];
private static byte[] REGISTRY_LOCK = new byte[0];
@@ -215,7 +215,7 @@
return;
try
{
- monitor.beginTask("Saving features...", 100);
+ monitor.beginTask(Messages.getString("XSLTRuntime.5"), 100); //$NON-NLS-1$
FeaturePreferences prefs = new FeaturePreferences();
Map<String,Map<String,String>> typeIdFeatures = new HashMap<String,Map<String,String>>(typeFeatures.size());
for (IProcessorType type : typeFeatures.keySet())
@@ -237,7 +237,7 @@
}
catch (Exception e)
{
- throw new CoreException(new Status(IStatus.ERROR,LaunchingPlugin.PLUGIN_ID,"Failed to save feature preferences",e));
+ throw new CoreException(new Status(IStatus.ERROR,LaunchingPlugin.PLUGIN_ID,Messages.getString("XSLTRuntime.6"),e)); //$NON-NLS-1$
}
finally
{
@@ -251,7 +251,7 @@
return;
try
{
- monitor.beginTask("Saving properties...", 100);
+ monitor.beginTask(Messages.getString("XSLTRuntime.7"), 100); //$NON-NLS-1$
OutputPropertyPreferences prefs = new OutputPropertyPreferences();
for (IProcessorType type : typeProperties.keySet())
{
@@ -270,7 +270,7 @@
}
catch (Exception e)
{
- throw new CoreException(new Status(IStatus.ERROR,LaunchingPlugin.PLUGIN_ID,"Failed to save output property preferences",e));
+ throw new CoreException(new Status(IStatus.ERROR,LaunchingPlugin.PLUGIN_ID,Messages.getString("XSLTRuntime.8"),e)); //$NON-NLS-1$
}
finally
{
@@ -284,7 +284,7 @@
return;
try
{
- monitor.beginTask("Saving processors...", 100);
+ monitor.beginTask(Messages.getString("XSLTRuntime.9"), 100); //$NON-NLS-1$
ProcessorPreferences prefs = new ProcessorPreferences();
if (defaultInstall != null)
prefs.setDefaultProcessorId(defaultInstall.getId());
@@ -302,7 +302,7 @@
}
catch (Exception e)
{
- throw new CoreException(new Status(IStatus.ERROR,LaunchingPlugin.PLUGIN_ID,"Failed to save process preferences",e));
+ throw new CoreException(new Status(IStatus.ERROR,LaunchingPlugin.PLUGIN_ID,Messages.getString("XSLTRuntime.10"),e)); //$NON-NLS-1$
}
finally
{
@@ -314,11 +314,11 @@
{
Properties props = new Properties();
if (JRE_DEFAULT_PROCESSOR_TYPE_ID.equals(typeId))
- props.put("indent", "yes");
+ props.put("indent", "yes"); //$NON-NLS-1$ //$NON-NLS-2$
else if (XSLLaunchConfigurationConstants.XALAN_TYPE_ID.equals(typeId))
- props.put("{http://xml.apache.org/xslt}indent-amount", "4");
+ props.put("{http://xml.apache.org/xslt}indent-amount", "4"); //$NON-NLS-1$ //$NON-NLS-2$
else if (XSLLaunchConfigurationConstants.SAXONB_TYPE_ID.equals(typeId))
- props.put("{http://saxon.sf.net/}indent-spaces", "4");
+ props.put("{http://saxon.sf.net/}indent-spaces", "4"); //$NON-NLS-1$ //$NON-NLS-2$
return props;
}
@@ -331,7 +331,7 @@
IContentType[] types = contentTypeManager.findContentTypesFor(file.getName());
for (IContentType contentType : types)
{
- if (contentType.isKindOf(contentTypeManager.getContentType("org.eclipse.core.runtime.xml")) || contentType.isKindOf(contentTypeManager.getContentType("org.eclipse.wst.xml.core.xmlsource")))
+ if (contentType.isKindOf(contentTypeManager.getContentType("org.eclipse.core.runtime.xml")) || contentType.isKindOf(contentTypeManager.getContentType("org.eclipse.wst.xml.core.xmlsource"))) //$NON-NLS-1$ //$NON-NLS-2$
{
return true;
}
@@ -348,7 +348,7 @@
IContentType[] types = contentTypeManager.findContentTypesFor(file.getName());
for (IContentType contentType : types)
{
- if (contentType.isKindOf(contentTypeManager.getContentType("org.eclipse.wst.xml.core.xslsource")))
+ if (contentType.isKindOf(contentTypeManager.getContentType("org.eclipse.wst.xml.core.xslsource"))) //$NON-NLS-1$
{
return true;
}
diff --git a/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/launching/config/LaunchAttribute.java b/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/launching/config/LaunchAttribute.java
index d5478fa..e6b3c86 100644
--- a/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/launching/config/LaunchAttribute.java
+++ b/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/launching/config/LaunchAttribute.java
@@ -15,16 +15,16 @@
public class LaunchAttribute
{
- public static final String TYPE_SUFFIX = ".TYPE";
- public static final String VALUE_SUFFIX = ".VALUE";
+ public static final String TYPE_SUFFIX = ".TYPE"; //$NON-NLS-1$
+ public static final String VALUE_SUFFIX = ".VALUE"; //$NON-NLS-1$
- public static final String TYPE_STRING = "string";
- public static final String TYPE_BOOLEAN = "boolean";
- public static final String TYPE_INT = "int";
- public static final String TYPE_DOUBLE = "double";
- public static final String TYPE_FLOAT = "float";
- public static final String TYPE_CLASS = "class";
- public static final String TYPE_OBJECT = "object";
+ public static final String TYPE_STRING = "string"; //$NON-NLS-1$
+ public static final String TYPE_BOOLEAN = "boolean"; //$NON-NLS-1$
+ public static final String TYPE_INT = "int"; //$NON-NLS-1$
+ public static final String TYPE_DOUBLE = "double"; //$NON-NLS-1$
+ public static final String TYPE_FLOAT = "float"; //$NON-NLS-1$
+ public static final String TYPE_CLASS = "class"; //$NON-NLS-1$
+ public static final String TYPE_OBJECT = "object"; //$NON-NLS-1$
public final String uri;
public String type;
diff --git a/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/launching/config/LaunchFeatures.java b/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/launching/config/LaunchFeatures.java
index e13789b..d531464 100644
--- a/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/launching/config/LaunchFeatures.java
+++ b/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/launching/config/LaunchFeatures.java
@@ -64,7 +64,7 @@
{
Document doc = PreferenceUtil.getDocument();
- Element featuresEl = doc.createElement("Features");
+ Element featuresEl = doc.createElement("Features"); //$NON-NLS-1$
doc.appendChild(featuresEl);
for (Iterator<LaunchAttribute> iter = features.iterator(); iter.hasNext();)
@@ -72,10 +72,10 @@
LaunchAttribute feature = (LaunchAttribute) iter.next();
if (feature.value == null)
continue;
- Element featureEl = doc.createElement("Feature");
- featureEl.setAttribute("name", feature.uri);
- featureEl.setAttribute("type", feature.type);
- featureEl.setAttribute("value", feature.value);
+ Element featureEl = doc.createElement("Feature"); //$NON-NLS-1$
+ featureEl.setAttribute("name", feature.uri); //$NON-NLS-1$
+ featureEl.setAttribute("type", feature.type); //$NON-NLS-1$
+ featureEl.setAttribute("value", feature.value); //$NON-NLS-1$
featuresEl.appendChild(featureEl);
}
@@ -90,13 +90,13 @@
Element featuresEl = doc.getDocumentElement();
- NodeList featureEls = featuresEl.getElementsByTagName("Feature");
+ NodeList featureEls = featuresEl.getElementsByTagName("Feature"); //$NON-NLS-1$
for (int i = 0; i < featureEls.getLength(); i++)
{
Element featureEl = (Element) featureEls.item(i);
- String name = featureEl.getAttribute("name");
- String type = featureEl.getAttribute("type");
- String value = featureEl.getAttribute("value");
+ String name = featureEl.getAttribute("name"); //$NON-NLS-1$
+ String type = featureEl.getAttribute("type"); //$NON-NLS-1$
+ String value = featureEl.getAttribute("value"); //$NON-NLS-1$
pdef.addFeature(new LaunchAttribute(name, type, value));
}
diff --git a/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/launching/config/LaunchHelper.java b/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/launching/config/LaunchHelper.java
index ab3d1de..7d79978 100644
--- a/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/launching/config/LaunchHelper.java
+++ b/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/launching/config/LaunchHelper.java
@@ -153,19 +153,19 @@
}
catch (FileNotFoundException e)
{
- throw new CoreException(new Status(IStatus.ERROR, LaunchingPlugin.PLUGIN_ID, IStatus.ERROR, "File not found", e));
+ throw new CoreException(new Status(IStatus.ERROR, LaunchingPlugin.PLUGIN_ID, IStatus.ERROR, Messages.getString("LaunchHelper.0"), e)); //$NON-NLS-1$
}
catch (IOException e)
{
- throw new CoreException(new Status(IStatus.ERROR, LaunchingPlugin.PLUGIN_ID, IStatus.ERROR, "IO Exception", e));
+ throw new CoreException(new Status(IStatus.ERROR, LaunchingPlugin.PLUGIN_ID, IStatus.ERROR, Messages.getString("LaunchHelper.1"), e)); //$NON-NLS-1$
}
catch (ParserConfigurationException e)
{
- throw new CoreException(new Status(IStatus.ERROR, LaunchingPlugin.PLUGIN_ID, IStatus.ERROR, "ParserConfigurationException", e));
+ throw new CoreException(new Status(IStatus.ERROR, LaunchingPlugin.PLUGIN_ID, IStatus.ERROR, "ParserConfigurationException", e)); //$NON-NLS-1$
}
catch (TransformerException e)
{
- throw new CoreException(new Status(IStatus.ERROR, LaunchingPlugin.PLUGIN_ID, IStatus.ERROR, "TransformerException", e));
+ throw new CoreException(new Status(IStatus.ERROR, LaunchingPlugin.PLUGIN_ID, IStatus.ERROR, "TransformerException", e)); //$NON-NLS-1$
}
finally
{
@@ -331,7 +331,7 @@
// TODO: where is the default output file? And must share this with
// the value displayed in the UI.
outputFile = (IPath) sourceFile.clone();
- outputFile = outputFile.addFileExtension("out").addFileExtension("xml");
+ outputFile = outputFile.addFileExtension("out").addFileExtension("xml"); //$NON-NLS-1$ //$NON-NLS-2$
}
return outputFile.toFile();
}
@@ -351,7 +351,7 @@
boolean useDefaultProcessor = configuration.getAttribute(XSLLaunchConfigurationConstants.ATTR_USE_DEFAULT_PROCESSOR, true);
if (useDefaultProcessor)
return XSLTRuntime.getDefaultProcessor();
- String processorId = configuration.getAttribute(XSLLaunchConfigurationConstants.ATTR_PROCESSOR, "");
+ String processorId = configuration.getAttribute(XSLLaunchConfigurationConstants.ATTR_PROCESSOR, ""); //$NON-NLS-1$
IProcessorInstall processor = XSLTRuntime.getProcessor(processorId);
return processor;
}
diff --git a/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/launching/config/LaunchPipeline.java b/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/launching/config/LaunchPipeline.java
index 7cde436..4ba2983 100644
--- a/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/launching/config/LaunchPipeline.java
+++ b/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/launching/config/LaunchPipeline.java
@@ -73,17 +73,17 @@
try
{
Document doc = PreferenceUtil.getDocument();
- Element rootEl = doc.createElement("Pipeline");
+ Element rootEl = doc.createElement("Pipeline"); //$NON-NLS-1$
doc.appendChild(rootEl);
- Element opEl = doc.createElement("OutputProperties");
+ Element opEl = doc.createElement("OutputProperties"); //$NON-NLS-1$
rootEl.appendChild(opEl);
for (Object element : outputProperties.entrySet())
{
Map.Entry entry = (Map.Entry) element;
- Element propEl = doc.createElement("Property");
- propEl.setAttribute("name", (String) entry.getKey());
- propEl.setAttribute("value", (String) entry.getValue());
+ Element propEl = doc.createElement("Property"); //$NON-NLS-1$
+ propEl.setAttribute("name", (String) entry.getKey()); //$NON-NLS-1$
+ propEl.setAttribute("value", (String) entry.getValue()); //$NON-NLS-1$
opEl.appendChild(propEl);
}
@@ -123,20 +123,20 @@
Element rootEl = doc.getDocumentElement();
- Element opEl = (Element) rootEl.getElementsByTagName("OutputProperties").item(0);
+ Element opEl = (Element) rootEl.getElementsByTagName("OutputProperties").item(0); //$NON-NLS-1$
if (opEl != null)
{
- NodeList propEls = opEl.getElementsByTagName("Property");
+ NodeList propEls = opEl.getElementsByTagName("Property"); //$NON-NLS-1$
for (int i = 0; i < propEls.getLength(); i++)
{
Element propEl = (Element) propEls.item(i);
- String name = propEl.getAttribute("name");
- String value = propEl.getAttribute("value");
+ String name = propEl.getAttribute("name"); //$NON-NLS-1$
+ String value = propEl.getAttribute("value"); //$NON-NLS-1$
pdef.addOutputProperty(name, value);
}
}
- NodeList transformEls = rootEl.getElementsByTagName("Transform");
+ NodeList transformEls = rootEl.getElementsByTagName("Transform"); //$NON-NLS-1$
for (int i = 0; i < transformEls.getLength(); i++)
{
Element transformEl = (Element) transformEls.item(i);
diff --git a/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/launching/config/LaunchProperties.java b/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/launching/config/LaunchProperties.java
index ddd9212..5cf0e6c 100644
--- a/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/launching/config/LaunchProperties.java
+++ b/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/launching/config/LaunchProperties.java
@@ -53,7 +53,7 @@
{
Document doc = PreferenceUtil.getDocument();
- Element featuresEl = doc.createElement("Properties");
+ Element featuresEl = doc.createElement("Properties"); //$NON-NLS-1$
doc.appendChild(featuresEl);
for (Iterator<?> iter = properties.entrySet().iterator(); iter.hasNext();)
@@ -63,9 +63,9 @@
String value = (String) entry.getValue();
if (value == null)
continue;
- Element featureEl = doc.createElement("Property");
- featureEl.setAttribute("name", name);
- featureEl.setAttribute("value", value);
+ Element featureEl = doc.createElement("Property"); //$NON-NLS-1$
+ featureEl.setAttribute("name", name); //$NON-NLS-1$
+ featureEl.setAttribute("value", value); //$NON-NLS-1$
featuresEl.appendChild(featureEl);
}
@@ -80,12 +80,12 @@
Element featuresEl = doc.getDocumentElement();
- NodeList featureEls = featuresEl.getElementsByTagName("Property");
+ NodeList featureEls = featuresEl.getElementsByTagName("Property"); //$NON-NLS-1$
for (int i = 0; i < featureEls.getLength(); i++)
{
Element featureEl = (Element) featureEls.item(i);
- String name = featureEl.getAttribute("name");
- String value = featureEl.getAttribute("value");
+ String name = featureEl.getAttribute("name"); //$NON-NLS-1$
+ String value = featureEl.getAttribute("value"); //$NON-NLS-1$
pdef.setProperty(name, value);
}
diff --git a/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/launching/config/LaunchTransform.java b/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/launching/config/LaunchTransform.java
index f845496..e7ea6b8 100644
--- a/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/launching/config/LaunchTransform.java
+++ b/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/launching/config/LaunchTransform.java
@@ -26,8 +26,8 @@
public class LaunchTransform
{
- public static final String RESOURCE_TYPE = "resource";
- public static final String EXTERNAL_TYPE = "external";
+ public static final String RESOURCE_TYPE = "resource"; //$NON-NLS-1$
+ public static final String EXTERNAL_TYPE = "external"; //$NON-NLS-1$
private final String stylesheet;
private final String pathType;
@@ -106,20 +106,20 @@
public Element asXML(Document doc)
{
- Element tdefEl = doc.createElement("Transform");
- tdefEl.setAttribute("path", stylesheet);
- tdefEl.setAttribute("pathType", pathType);
+ Element tdefEl = doc.createElement("Transform"); //$NON-NLS-1$
+ tdefEl.setAttribute("path", stylesheet); //$NON-NLS-1$
+ tdefEl.setAttribute("pathType", pathType); //$NON-NLS-1$
if (resolver != null)
- tdefEl.setAttribute("uriResolver", resolver);
- Element paramsEl = doc.createElement("Parameters");
+ tdefEl.setAttribute("uriResolver", resolver); //$NON-NLS-1$
+ Element paramsEl = doc.createElement("Parameters"); //$NON-NLS-1$
tdefEl.appendChild(paramsEl);
for (Iterator<LaunchAttribute> iter = parameters.iterator(); iter.hasNext();)
{
LaunchAttribute param = (LaunchAttribute) iter.next();
- Element propEl = doc.createElement("Parameter");
- propEl.setAttribute("name", param.uri);
- propEl.setAttribute("type", param.type);
- propEl.setAttribute("value", param.value);
+ Element propEl = doc.createElement("Parameter"); //$NON-NLS-1$
+ propEl.setAttribute("name", param.uri); //$NON-NLS-1$
+ propEl.setAttribute("type", param.type); //$NON-NLS-1$
+ propEl.setAttribute("value", param.value); //$NON-NLS-1$
paramsEl.appendChild(propEl);
}
return tdefEl;
@@ -127,22 +127,22 @@
public static LaunchTransform fromXML(Element transformEl)
{
- String path = transformEl.getAttribute("path");
- String pathType = transformEl.getAttribute("pathType");
+ String path = transformEl.getAttribute("path"); //$NON-NLS-1$
+ String pathType = transformEl.getAttribute("pathType"); //$NON-NLS-1$
LaunchTransform tdef = new LaunchTransform(path, pathType);
- String uriResolver = transformEl.getAttribute("uriResolver");
+ String uriResolver = transformEl.getAttribute("uriResolver"); //$NON-NLS-1$
tdef.setResolver(uriResolver);
- Element paramsEl = (Element) transformEl.getElementsByTagName("Parameters").item(0);
- NodeList paramEls = paramsEl.getElementsByTagName("Parameter");
+ Element paramsEl = (Element) transformEl.getElementsByTagName("Parameters").item(0); //$NON-NLS-1$
+ NodeList paramEls = paramsEl.getElementsByTagName("Parameter"); //$NON-NLS-1$
for (int i = 0; i < paramEls.getLength(); i++)
{
Element paramEl = (Element) paramEls.item(i);
- String name = paramEl.getAttribute("name");
- String type = paramEl.getAttribute("type");
- String value = paramEl.getAttribute("value");
+ String name = paramEl.getAttribute("name"); //$NON-NLS-1$
+ String type = paramEl.getAttribute("type"); //$NON-NLS-1$
+ String value = paramEl.getAttribute("value"); //$NON-NLS-1$
tdef.addParameter(new LaunchAttribute(name, type, value));
}
diff --git a/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/launching/config/Messages.java b/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/launching/config/Messages.java
new file mode 100644
index 0000000..c62e7c0
--- /dev/null
+++ b/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/launching/config/Messages.java
@@ -0,0 +1,22 @@
+package org.eclipse.wst.xsl.launching.config;
+
+import java.util.MissingResourceException;
+import java.util.ResourceBundle;
+
+public class Messages {
+ private static final String BUNDLE_NAME = "org.eclipse.wst.xsl.launching.config.messages"; //$NON-NLS-1$
+
+ private static final ResourceBundle RESOURCE_BUNDLE = ResourceBundle
+ .getBundle(BUNDLE_NAME);
+
+ private Messages() {
+ }
+
+ public static String getString(String key) {
+ try {
+ return RESOURCE_BUNDLE.getString(key);
+ } catch (MissingResourceException e) {
+ return '!' + key + '!';
+ }
+ }
+}
diff --git a/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/launching/config/messages.properties b/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/launching/config/messages.properties
new file mode 100644
index 0000000..f08087e
--- /dev/null
+++ b/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/launching/config/messages.properties
@@ -0,0 +1,2 @@
+LaunchHelper.0=File not found
+LaunchHelper.1=IO Exception
diff --git a/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/launching/messages.properties b/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/launching/messages.properties
new file mode 100644
index 0000000..d75ea07
--- /dev/null
+++ b/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/launching/messages.properties
@@ -0,0 +1,6 @@
+XSLTRuntime.10=Failed to save process preferences
+XSLTRuntime.5=Saving features...
+XSLTRuntime.6=Failed to save feature preferences
+XSLTRuntime.7=Saving properties...
+XSLTRuntime.8=Failed to save output property preferences
+XSLTRuntime.9=Saving processors...
diff --git a/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/launching/model/IXSLConstants.java b/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/launching/model/IXSLConstants.java
index f449f37..1fa47da 100644
--- a/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/launching/model/IXSLConstants.java
+++ b/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/launching/model/IXSLConstants.java
@@ -13,7 +13,7 @@
public interface IXSLConstants
{
- public static final String ID_XSL_DEBUG_MODEL = "org.eclipse.wst.xsl.launching.XSLDebugModel";
- public static final String MARKER_ID = "org.eclipse.wst.xsl.launching.xslLineBreakpointMarker";
+ public static final String ID_XSL_DEBUG_MODEL = "org.eclipse.wst.xsl.launching.XSLDebugModel"; //$NON-NLS-1$
+ public static final String MARKER_ID = "org.eclipse.wst.xsl.launching.xslLineBreakpointMarker"; //$NON-NLS-1$
}
diff --git a/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/launching/model/Messages.java b/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/launching/model/Messages.java
new file mode 100644
index 0000000..0e9a27a
--- /dev/null
+++ b/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/launching/model/Messages.java
@@ -0,0 +1,22 @@
+package org.eclipse.wst.xsl.launching.model;
+
+import java.util.MissingResourceException;
+import java.util.ResourceBundle;
+
+public class Messages {
+ private static final String BUNDLE_NAME = "org.eclipse.wst.xsl.launching.model.messages"; //$NON-NLS-1$
+
+ private static final ResourceBundle RESOURCE_BUNDLE = ResourceBundle
+ .getBundle(BUNDLE_NAME);
+
+ private Messages() {
+ }
+
+ public static String getString(String key) {
+ try {
+ return RESOURCE_BUNDLE.getString(key);
+ } catch (MissingResourceException e) {
+ return '!' + key + '!';
+ }
+ }
+}
diff --git a/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/launching/model/XSLDebugElement.java b/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/launching/model/XSLDebugElement.java
index 9986558..5576c6e 100644
--- a/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/launching/model/XSLDebugElement.java
+++ b/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/launching/model/XSLDebugElement.java
@@ -28,7 +28,7 @@
return IXSLConstants.ID_XSL_DEBUG_MODEL;
}
- @SuppressWarnings("unchecked")
+ @SuppressWarnings("unchecked") //$NON-NLS-1$
@Override
public Object getAdapter(Class adapter) {
if (adapter == ITerminate.class) {
diff --git a/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/launching/model/XSLDebugTarget.java b/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/launching/model/XSLDebugTarget.java
index 682b870..2614781 100644
--- a/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/launching/model/XSLDebugTarget.java
+++ b/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/launching/model/XSLDebugTarget.java
@@ -97,7 +97,7 @@
}
catch (IOException e)
{
- abort("Unable to connect to debugger", e);
+ abort(Messages.getString("XSLDebugTarget.0"), e); //$NON-NLS-1$
}
this.thread = new XSLThread(this);
this.threads = new IThread[]{ thread };
@@ -125,7 +125,7 @@
break;
try
{
- socket = new Socket("localhost",port);
+ socket = new Socket(Messages.getString("XSLDebugTarget.1"),port); //$NON-NLS-1$
}
catch (ConnectException e)
{}
@@ -141,7 +141,7 @@
{}
}
if (socket == null && !process.isTerminated())
- throw new CoreException(new Status(Status.ERROR, LaunchingPlugin.PLUGIN_ID, "Could not connect to socket "+port+" after "+CONNECT_ATTEMPTS+" attempts"));
+ throw new CoreException(new Status(Status.ERROR, LaunchingPlugin.PLUGIN_ID, Messages.getString("XSLDebugTarget.2")+port+Messages.getString("XSLDebugTarget.3")+CONNECT_ATTEMPTS+Messages.getString("XSLDebugTarget.4"))); //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
return socket;
}
@@ -168,7 +168,7 @@
{
IProcessorInstall install = XSLTLaunchConfigurationDelegate.getProcessorInstall(getLaunch().getLaunchConfiguration(), ILaunchManager.DEBUG_MODE);
String type = install.getProcessorType().getLabel();
- name = type + " [" + install.getName() + "]";
+ name = type + " [" + install.getName() + "]"; //$NON-NLS-1$ //$NON-NLS-2$
}
catch (CoreException e)
{
@@ -284,7 +284,7 @@
if (marker != null)
{
URL file = marker.getResource().getLocation().toFile().toURI().toURL();
- sendRequest(DebugConstants.REQUEST_ADD_BREAKPOINT + " " + file + " " + lb.getLineNumber());
+ sendRequest(DebugConstants.REQUEST_ADD_BREAKPOINT + " " + file + " " + lb.getLineNumber()); //$NON-NLS-1$ //$NON-NLS-2$
}
}
catch (CoreException e)
@@ -314,7 +314,7 @@
if (marker != null)
{
URL file = marker.getResource().getLocation().toFile().toURI().toURL();
- sendRequest(DebugConstants.REQUEST_REMOVE_BREAKPOINT + " " + file + " " + lb.getLineNumber());
+ sendRequest(DebugConstants.REQUEST_REMOVE_BREAKPOINT + " " + file + " " + lb.getLineNumber()); //$NON-NLS-1$ //$NON-NLS-2$
}
}
catch (CoreException e)
@@ -425,7 +425,7 @@
{
stale = false;
String framesData = sendRequest(DebugConstants.REQUEST_STACK);
- String[] frames = framesData.split("\\$\\$\\$");
+ String[] frames = framesData.split("\\$\\$\\$"); //$NON-NLS-1$
IStackFrame[] sf = new IStackFrame[frames.length];
List<IStackFrame> currentFrames = Arrays.asList(stackFramesCache);
for (int i = 0; i < frames.length; i++)
@@ -530,8 +530,8 @@
if (var == null)
{
var = new XSLVariable(this,varId);
- String res = sendRequest(DebugConstants.REQUEST_VARIABLE + " " + varId);
- String[] data = res.split("&");
+ String res = sendRequest(DebugConstants.REQUEST_VARIABLE + " " + varId); //$NON-NLS-1$
+ String[] data = res.split("&"); //$NON-NLS-1$
var.setScope(data[0]);
var.setName(data[1]);
variableMapCache.put(varId,var);
@@ -549,21 +549,21 @@
{
if (isSuspended())
{
- String res = sendRequest(DebugConstants.REQUEST_VALUE + " " + variable.getId());
- String[] data = res.split("&");
+ String res = sendRequest(DebugConstants.REQUEST_VALUE + " " + variable.getId()); //$NON-NLS-1$
+ String[] data = res.split("&"); //$NON-NLS-1$
String type = data[0];
String theval;
if (data.length > 1)
theval = data[1];
else
- theval = "";
+ theval = ""; //$NON-NLS-1$
value = new XSLValue(this, type, theval);
valueMapCache.put(variable, value);
}
else
{
// anything as long as not null!
- value = new XSLValue(this, "G", "");
+ value = new XSLValue(this, "G", ""); //$NON-NLS-1$ //$NON-NLS-2$
}
}
return value;
@@ -586,7 +586,7 @@
}
catch (IOException e)
{
- abort("Request failed: " + request, e);
+ abort(Messages.getString("XSLDebugTarget.19") + request, e); //$NON-NLS-1$
}
}
return response;
@@ -631,14 +631,14 @@
public EventDispatchJob()
{
- super("Event Dispatch");
+ super(Messages.getString("XSLDebugTarget.20")); //$NON-NLS-1$
setSystem(true);
}
@Override
protected IStatus run(IProgressMonitor monitor)
{
- String event = "";
+ String event = ""; //$NON-NLS-1$
while (!isTerminated() && event != null)
{
try
@@ -648,11 +648,11 @@
{
thread.setBreakpoints(null);
thread.setStepping(false);
- if (event.equals("ready"))
+ if (event.equals("ready")) //$NON-NLS-1$
{
ready();
}
- else if (event.equals("stopped"))
+ else if (event.equals("stopped")) //$NON-NLS-1$
{
try
{
@@ -662,18 +662,18 @@
{
}
}
- else if (event.equals("terminated"))
+ else if (event.equals("terminated")) //$NON-NLS-1$
{
terminated();
}
- else if (event.startsWith("resumed"))
+ else if (event.startsWith("resumed")) //$NON-NLS-1$
{
- if (event.endsWith("step"))
+ if (event.endsWith("step")) //$NON-NLS-1$
{
thread.setStepping(true);
resumed(DebugEvent.STEP_OVER);
}
- else if (event.endsWith("client"))
+ else if (event.endsWith("client")) //$NON-NLS-1$
{
resumed(DebugEvent.CLIENT_REQUEST);
}
@@ -683,19 +683,19 @@
// " + event);
}
}
- else if (event.startsWith("suspended"))
+ else if (event.startsWith("suspended")) //$NON-NLS-1$
{
// clear down the frames so that they are re-fetched
ressetStackFramesCache();
- if (event.endsWith("client"))
+ if (event.endsWith("client")) //$NON-NLS-1$
{
suspended(DebugEvent.CLIENT_REQUEST);
}
- else if (event.endsWith("step"))
+ else if (event.endsWith("step")) //$NON-NLS-1$
{
suspended(DebugEvent.STEP_END);
}
- else if (event.indexOf("breakpoint") >= 0)
+ else if (event.indexOf("breakpoint") >= 0) //$NON-NLS-1$
{
breakpointHit(event);
}
diff --git a/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/launching/model/XSLLineBreakpoint.java b/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/launching/model/XSLLineBreakpoint.java
index cd8e4ca..657e2a8 100644
--- a/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/launching/model/XSLLineBreakpoint.java
+++ b/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/launching/model/XSLLineBreakpoint.java
@@ -39,7 +39,7 @@
setMarker(marker);
marker.setAttribute(IBreakpoint.ID, getModelIdentifier());
marker.setAttribute(IBreakpoint.ENABLED, Boolean.TRUE);
- marker.setAttribute(IMarker.MESSAGE, "Line Breakpoint: " + resource.getName() + " [line: " + lineNumber + "]");
+ marker.setAttribute(IMarker.MESSAGE, Messages.getString("XSLLineBreakpoint.0") + resource.getName() + " [line: " + lineNumber + "]"); //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
marker.setAttribute(IMarker.LINE_NUMBER, lineNumber);
marker.setAttribute(IMarker.CHAR_START, new Integer(charStart));
diff --git a/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/launching/model/XSLStackFrame.java b/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/launching/model/XSLStackFrame.java
index 8e0ae1a..7a49a26 100644
--- a/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/launching/model/XSLStackFrame.java
+++ b/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/launching/model/XSLStackFrame.java
@@ -44,7 +44,7 @@
private void init(String data,IXSLDebugTarget debugTarget)
{
- String[] strings = data.split("\\|");
+ String[] strings = data.split("\\|"); //$NON-NLS-1$
String fileName = strings[0];
try
{
@@ -59,12 +59,12 @@
String safename = strings[3];
int theIndex;
- while ((theIndex = safename.indexOf("%@_PIPE_@%")) != -1)
+ while ((theIndex = safename.indexOf("%@_PIPE_@%")) != -1) //$NON-NLS-1$
{
- safename = safename.substring(0, theIndex) + "|" + safename.substring(theIndex + "%@_PIPE_@%".length(), safename.length());
+ safename = safename.substring(0, theIndex) + "|" + safename.substring(theIndex + "%@_PIPE_@%".length(), safename.length()); //$NON-NLS-1$ //$NON-NLS-2$
}
- name = p.lastSegment() + " " + safename;
+ name = p.lastSegment() + " " + safename; //$NON-NLS-1$
variables = new XSLVariable[strings.length-4];
for (int i=0;i<variables.length;i++)
@@ -119,7 +119,7 @@
public String getName() throws DebugException
{
- return name + " line: " + lineNumber;
+ return name + Messages.getString("XSLStackFrame.5") + lineNumber; //$NON-NLS-1$
}
public IRegisterGroup[] getRegisterGroups() throws DebugException
diff --git a/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/launching/model/XSLThread.java b/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/launching/model/XSLThread.java
index 1c4d899..1e88e0e 100644
--- a/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/launching/model/XSLThread.java
+++ b/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/launching/model/XSLThread.java
@@ -71,7 +71,7 @@
public String getName() throws DebugException
{
- return "Thread[1]";
+ return "Thread[1]"; //$NON-NLS-1$
}
public IBreakpoint[] getBreakpoints()
diff --git a/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/launching/model/XSLValue.java b/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/launching/model/XSLValue.java
index ff64fde..d6a391f 100644
--- a/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/launching/model/XSLValue.java
+++ b/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/launching/model/XSLValue.java
@@ -34,8 +34,8 @@
public String getValueString() throws DebugException
{
- if ("string".equals(type))
- return "'"+fValue+"'";
+ if ("string".equals(type)) //$NON-NLS-1$
+ return "'"+fValue+"'"; //$NON-NLS-1$ //$NON-NLS-2$
return fValue;
}
diff --git a/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/launching/model/XSLVariable.java b/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/launching/model/XSLVariable.java
index c36ccea..71805f7 100644
--- a/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/launching/model/XSLVariable.java
+++ b/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/launching/model/XSLVariable.java
@@ -17,9 +17,9 @@
public class XSLVariable extends XSLDebugElement implements IVariable
{
- public static final String LOCAL_SCOPE = "L";
- public static final String TUNNEL_SCOPE = "T";
- public static final String GLOBAL_SCOPE = "G";
+ public static final String LOCAL_SCOPE = "L"; //$NON-NLS-1$
+ public static final String TUNNEL_SCOPE = "T"; //$NON-NLS-1$
+ public static final String GLOBAL_SCOPE = "G"; //$NON-NLS-1$
private final int id;
private String fName;
@@ -55,8 +55,8 @@
public String getReferenceTypeName() throws DebugException
{
if (GLOBAL_SCOPE.equals(scope))
- return "global";
- return "local";
+ return "global"; //$NON-NLS-1$
+ return "local"; //$NON-NLS-1$
}
public boolean hasValueChanged() throws DebugException
diff --git a/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/launching/model/messages.properties b/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/launching/model/messages.properties
new file mode 100644
index 0000000..8630d45
--- /dev/null
+++ b/bundles/org.eclipse.wst.xsl.launching/src/org/eclipse/wst/xsl/launching/model/messages.properties
@@ -0,0 +1,9 @@
+XSLDebugTarget.0=Unable to connect to debugger
+XSLDebugTarget.1=localhost
+XSLDebugTarget.19=Request failed:
+XSLDebugTarget.2=Could not connect to socket
+XSLDebugTarget.20=Event Dispatch
+XSLDebugTarget.3=\ after
+XSLDebugTarget.4=\ attempts
+XSLLineBreakpoint.0=Line Breakpoint:
+XSLStackFrame.5=\ line:
diff --git a/bundles/org.eclipse.wst.xsl.ui/src/org/eclipse/wst/xsl/ui/internal/StructuredTextViewerConfigurationXSL.java b/bundles/org.eclipse.wst.xsl.ui/src/org/eclipse/wst/xsl/ui/internal/StructuredTextViewerConfigurationXSL.java
index 3dccb96..0b46208 100644
--- a/bundles/org.eclipse.wst.xsl.ui/src/org/eclipse/wst/xsl/ui/internal/StructuredTextViewerConfigurationXSL.java
+++ b/bundles/org.eclipse.wst.xsl.ui/src/org/eclipse/wst/xsl/ui/internal/StructuredTextViewerConfigurationXSL.java
@@ -26,7 +26,7 @@
* @author dcarver
*
*/
-@SuppressWarnings({ "restriction"})
+@SuppressWarnings({ "restriction"}) //$NON-NLS-1$
public class StructuredTextViewerConfigurationXSL extends
StructuredTextViewerConfigurationXML {
diff --git a/bundles/org.eclipse.wst.xsl.ui/src/org/eclipse/wst/xsl/ui/internal/XSLTUIPlugin.java b/bundles/org.eclipse.wst.xsl.ui/src/org/eclipse/wst/xsl/ui/internal/XSLTUIPlugin.java
index 349f423..80f9ea5 100644
--- a/bundles/org.eclipse.wst.xsl.ui/src/org/eclipse/wst/xsl/ui/internal/XSLTUIPlugin.java
+++ b/bundles/org.eclipse.wst.xsl.ui/src/org/eclipse/wst/xsl/ui/internal/XSLTUIPlugin.java
@@ -23,7 +23,7 @@
/**
* The Plugin ID
*/
- public static final String PLUGIN_ID = "org.eclipse.wst.xsl.ui";
+ public static final String PLUGIN_ID = "org.eclipse.wst.xsl.ui"; //$NON-NLS-1$
// The shared instance
private static XSLTUIPlugin plugin;
diff --git a/bundles/org.eclipse.wst.xsl.ui/src/org/eclipse/wst/xsl/ui/internal/XSLUIPlugin.java b/bundles/org.eclipse.wst.xsl.ui/src/org/eclipse/wst/xsl/ui/internal/XSLUIPlugin.java
index 69d83e3..0452513 100644
--- a/bundles/org.eclipse.wst.xsl.ui/src/org/eclipse/wst/xsl/ui/internal/XSLUIPlugin.java
+++ b/bundles/org.eclipse.wst.xsl.ui/src/org/eclipse/wst/xsl/ui/internal/XSLUIPlugin.java
@@ -58,7 +58,7 @@
/**
* The plugin id for this plugin.
*/
- static public String PLUGIN_ID = "org.eclipse.wst.xsl.ui";
+ static public String PLUGIN_ID = "org.eclipse.wst.xsl.ui"; //$NON-NLS-1$
/**
* Constructor Class
*/
@@ -136,7 +136,7 @@
*/
public TemplateStore getTemplateStore() {
if (fTemplateStore == null) {
- fTemplateStore = new ContributionTemplateStore(getTemplateContextRegistry(), getPreferenceStore(), "org.eclipse.wst.xsl.ui.xpath_custom_templates");
+ fTemplateStore = new ContributionTemplateStore(getTemplateContextRegistry(), getPreferenceStore(), "org.eclipse.wst.xsl.ui.xpath_custom_templates"); //$NON-NLS-1$
try {
fTemplateStore.load();
}
@@ -155,12 +155,12 @@
public ContextTypeRegistry getTemplateContextRegistry() {
if (fContextTypeRegistry == null) {
ContributionContextTypeRegistry registry = new ContributionContextTypeRegistry();
- registry.addContextType("xsl_xpath");
- registry.addContextType("xpath_operator");
- registry.addContextType("xpath_axis");
- registry.addContextType("exslt_function");
- registry.addContextType("xpath_2");
- registry.addContextType("extension_function");
+ registry.addContextType("xsl_xpath"); //$NON-NLS-1$
+ registry.addContextType("xpath_operator"); //$NON-NLS-1$
+ registry.addContextType("xpath_axis"); //$NON-NLS-1$
+ registry.addContextType("exslt_function"); //$NON-NLS-1$
+ registry.addContextType("xpath_2"); //$NON-NLS-1$
+ registry.addContextType("extension_function"); //$NON-NLS-1$
fContextTypeRegistry = registry;
}
diff --git a/bundles/org.eclipse.wst.xsl.ui/src/org/eclipse/wst/xsl/ui/internal/contentassist/Messages.java b/bundles/org.eclipse.wst.xsl.ui/src/org/eclipse/wst/xsl/ui/internal/contentassist/Messages.java
new file mode 100644
index 0000000..0fdf95c
--- /dev/null
+++ b/bundles/org.eclipse.wst.xsl.ui/src/org/eclipse/wst/xsl/ui/internal/contentassist/Messages.java
@@ -0,0 +1,32 @@
+package org.eclipse.wst.xsl.ui.internal.contentassist;
+
+import java.util.MissingResourceException;
+import java.util.ResourceBundle;
+
+/**
+ * TODO: Add Javadoc
+ * @author dcarver
+ *
+ */
+public class Messages {
+ private static final String BUNDLE_NAME = "org.eclipse.wst.xsl.ui.internal.contentassist.messages"; //$NON-NLS-1$
+
+ private static final ResourceBundle RESOURCE_BUNDLE = ResourceBundle
+ .getBundle(BUNDLE_NAME);
+
+ private Messages() {
+ }
+
+ /**
+ * TODO: Add Javadoc
+ * @param key
+ * @return
+ */
+ public static String getString(String key) {
+ try {
+ return RESOURCE_BUNDLE.getString(key);
+ } catch (MissingResourceException e) {
+ return '!' + key + '!';
+ }
+ }
+}
diff --git a/bundles/org.eclipse.wst.xsl.ui/src/org/eclipse/wst/xsl/ui/internal/contentassist/XPathCustomTemplateProposal.java b/bundles/org.eclipse.wst.xsl.ui/src/org/eclipse/wst/xsl/ui/internal/contentassist/XPathCustomTemplateProposal.java
index 2e52a40..226799c 100644
--- a/bundles/org.eclipse.wst.xsl.ui/src/org/eclipse/wst/xsl/ui/internal/contentassist/XPathCustomTemplateProposal.java
+++ b/bundles/org.eclipse.wst.xsl.ui/src/org/eclipse/wst/xsl/ui/internal/contentassist/XPathCustomTemplateProposal.java
@@ -40,7 +40,7 @@
* Purpose of this class is to make the additional proposal info into content
* fit for an HTML viewer (by escaping characters)
*/
-@SuppressWarnings("restriction")
+@SuppressWarnings("restriction") //$NON-NLS-1$
class XPathCustomTemplateProposal extends TemplateProposal implements IRelevanceCompletionProposal {
// copies of this class exist in:
// org.eclipse.jst.jsp.ui.internal.contentassist
@@ -70,7 +70,7 @@
}
public String getAdditionalProposalInfo() {
- String additionalInfo = "Description:\r\n" + fTemplate.getDescription();
+ String additionalInfo = Messages.getString("XPathCustomTemplateProposal.1") + fTemplate.getDescription(); //$NON-NLS-1$
return additionalInfo;
}
diff --git a/bundles/org.eclipse.wst.xsl.ui/src/org/eclipse/wst/xsl/ui/internal/contentassist/XPathTemplateCompletionProcessor.java b/bundles/org.eclipse.wst.xsl.ui/src/org/eclipse/wst/xsl/ui/internal/contentassist/XPathTemplateCompletionProcessor.java
index 5bb0ebb..bbca597 100755
--- a/bundles/org.eclipse.wst.xsl.ui/src/org/eclipse/wst/xsl/ui/internal/contentassist/XPathTemplateCompletionProcessor.java
+++ b/bundles/org.eclipse.wst.xsl.ui/src/org/eclipse/wst/xsl/ui/internal/contentassist/XPathTemplateCompletionProcessor.java
@@ -53,7 +53,7 @@
* @see org.eclipse.wst.xml.ui.
* @since 0.5M6
*/
-@SuppressWarnings("restriction")
+@SuppressWarnings("restriction") //$NON-NLS-1$
class XPathTemplateCompletionProcessor extends TemplateCompletionProcessor {
private static final class ProposalComparator implements Comparator {
public int compare(Object o1, Object o2) {
diff --git a/bundles/org.eclipse.wst.xsl.ui/src/org/eclipse/wst/xsl/ui/internal/contentassist/XSLContentAssistProcessor.java b/bundles/org.eclipse.wst.xsl.ui/src/org/eclipse/wst/xsl/ui/internal/contentassist/XSLContentAssistProcessor.java
index 4db27d7..15d9534 100644
--- a/bundles/org.eclipse.wst.xsl.ui/src/org/eclipse/wst/xsl/ui/internal/contentassist/XSLContentAssistProcessor.java
+++ b/bundles/org.eclipse.wst.xsl.ui/src/org/eclipse/wst/xsl/ui/internal/contentassist/XSLContentAssistProcessor.java
@@ -61,22 +61,22 @@
/**
* Retireve all global variables in the stylesheet.
*/
- private static final String XPATH_GLOBAL_VARIABLES = "/xsl:stylesheet/xsl:variable";
+ private static final String XPATH_GLOBAL_VARIABLES = "/xsl:stylesheet/xsl:variable"; //$NON-NLS-1$
/**
* Retrieve all global parameters in the stylesheet.
*/
- private static final String XPATH_GLOBAL_PARAMS = "/xsl:stylesheet/xsl:param";
+ private static final String XPATH_GLOBAL_PARAMS = "/xsl:stylesheet/xsl:param"; //$NON-NLS-1$
/**
* Limit selection of variables to those that are in the local scope.
*/
- private static final String XPATH_LOCAL_VARIABLES = "ancestor::xsl:template/descendant::xsl:variable";
+ private static final String XPATH_LOCAL_VARIABLES = "ancestor::xsl:template/descendant::xsl:variable"; //$NON-NLS-1$
/**
* Limit selection of params to those that are in the local scope.
*/
- private static final String XPATH_LOCAL_PARAMS = "ancestor::xsl:template/descendant::xsl:param";
+ private static final String XPATH_LOCAL_PARAMS = "ancestor::xsl:template/descendant::xsl:param"; //$NON-NLS-1$
/**
* XSL Namespace. We rely on the namespace not the prefix for identification.
@@ -188,7 +188,7 @@
if (nodes != null && nodes.getLength() > 0) {
for (int nodecnt = 0; nodecnt < nodes.getLength(); nodecnt++) {
Node node = nodes.item(nodecnt);
- String variableName = "$" + node.getAttributes().getNamedItem("name").getNodeValue();
+ String variableName = "$" + node.getAttributes().getNamedItem("name").getNodeValue(); //$NON-NLS-1$ //$NON-NLS-2$
contentAssistRequest.getReplacementLength();
XSLVariableCustomCompletionProposal proposal = new XSLVariableCustomCompletionProposal(variableName, offset, 0, variableName.length() + 1, XSLPluginImageHelper.getInstance().getImage(XSLPluginImages.IMG_VARIABLES), variableName, null, null, 0);
contentAssistRequest.addProposal(proposal);
diff --git a/bundles/org.eclipse.wst.xsl.ui/src/org/eclipse/wst/xsl/ui/internal/contentassist/messages.properties b/bundles/org.eclipse.wst.xsl.ui/src/org/eclipse/wst/xsl/ui/internal/contentassist/messages.properties
new file mode 100644
index 0000000..67591fe
--- /dev/null
+++ b/bundles/org.eclipse.wst.xsl.ui/src/org/eclipse/wst/xsl/ui/internal/contentassist/messages.properties
@@ -0,0 +1 @@
+XPathCustomTemplateProposal.1=Description:\r\n
diff --git a/bundles/org.eclipse.wst.xsl.ui/src/org/eclipse/wst/xsl/ui/internal/perspective/XMLPerspectiveFactory.java b/bundles/org.eclipse.wst.xsl.ui/src/org/eclipse/wst/xsl/ui/internal/perspective/XMLPerspectiveFactory.java
index 7d9e0be..7b18500 100644
--- a/bundles/org.eclipse.wst.xsl.ui/src/org/eclipse/wst/xsl/ui/internal/perspective/XMLPerspectiveFactory.java
+++ b/bundles/org.eclipse.wst.xsl.ui/src/org/eclipse/wst/xsl/ui/internal/perspective/XMLPerspectiveFactory.java
@@ -47,32 +47,32 @@
// Add the various views
IFolderLayout left =
- layout.createFolder("left", IPageLayout.LEFT, (float) 0.26, editorArea);
+ layout.createFolder("left", IPageLayout.LEFT, (float) 0.26, editorArea); //$NON-NLS-1$
left.addView(ProjectExplorer.VIEW_ID);
- IFolderLayout right = layout.createFolder("right", IPageLayout.RIGHT, (float) 0.75, editorArea);
+ IFolderLayout right = layout.createFolder("right", IPageLayout.RIGHT, (float) 0.75, editorArea); //$NON-NLS-1$
right.addView(IPageLayout.ID_OUTLINE);
// Add Outline to the bottom-left
IFolderLayout bottomLeft =
- layout.createFolder("bottom-left", IPageLayout.BOTTOM, (float) 0.50, "left");
- bottomLeft.addView("org.eclipse.wst.xml.views.XPathView");
- bottomLeft.addView("org.eclipse.wst.xml.xpath.ui.views.XPathNavigator");
+ layout.createFolder("bottom-left", IPageLayout.BOTTOM, (float) 0.50, "left"); //$NON-NLS-1$ //$NON-NLS-2$
+ bottomLeft.addView("org.eclipse.wst.xml.views.XPathView"); //$NON-NLS-1$
+ bottomLeft.addView("org.eclipse.wst.xml.xpath.ui.views.XPathNavigator"); //$NON-NLS-1$
- IFolderLayout bottom = layout.createFolder("bottom", IPageLayout.BOTTOM, (float) 0.75, editorArea);
+ IFolderLayout bottom = layout.createFolder("bottom", IPageLayout.BOTTOM, (float) 0.75, editorArea); //$NON-NLS-1$
bottom.addView(IPageLayout.ID_PROBLEM_VIEW);
bottom.addView(IPageLayout.ID_PROP_SHEET);
bottom.addView(IConsoleConstants.ID_CONSOLE_VIEW);
- bottom.addView("org.eclipse.wst.common.snippets.internal.ui.SnippetsView");
+ bottom.addView("org.eclipse.wst.common.snippets.internal.ui.SnippetsView"); //$NON-NLS-1$
- layout.addNewWizardShortcut("org.eclipse.wst.xml.ui.internal.wizards.NewXMLWizard");
- layout.addNewWizardShortcut("org.eclipse.wst.dtd.ui.internal.wizard.NewDTDWizard");
- layout.addNewWizardShortcut("org.eclipse.wst.xsd.ui.internal.wizards.NewXSDWizard");
- layout.addNewWizardShortcut("org.eclipse.wst.wsdl.ui");
- layout.addNewWizardShortcut("org.eclipse.ui.wizards.new.project");
- layout.addNewWizardShortcut("org.eclipse.ui.wizards.new.folder");
+ layout.addNewWizardShortcut("org.eclipse.wst.xml.ui.internal.wizards.NewXMLWizard"); //$NON-NLS-1$
+ layout.addNewWizardShortcut("org.eclipse.wst.dtd.ui.internal.wizard.NewDTDWizard"); //$NON-NLS-1$
+ layout.addNewWizardShortcut("org.eclipse.wst.xsd.ui.internal.wizards.NewXSDWizard"); //$NON-NLS-1$
+ layout.addNewWizardShortcut("org.eclipse.wst.wsdl.ui"); //$NON-NLS-1$
+ layout.addNewWizardShortcut("org.eclipse.ui.wizards.new.project"); //$NON-NLS-1$
+ layout.addNewWizardShortcut("org.eclipse.ui.wizards.new.folder"); //$NON-NLS-1$
- layout.addPerspectiveShortcut("org.eclipse.debug.ui.DebugPerspective");
+ layout.addPerspectiveShortcut("org.eclipse.debug.ui.DebugPerspective"); //$NON-NLS-1$
}
@@ -86,13 +86,13 @@
* @param layout
*/
private void addShortCutViews(IPageLayout layout) {
- layout.addShowViewShortcut("org.eclipse.wst.xml.xpath.ui.views.XPathNavigator");
+ layout.addShowViewShortcut("org.eclipse.wst.xml.xpath.ui.views.XPathNavigator"); //$NON-NLS-1$
layout.addShowViewShortcut(ProjectExplorer.VIEW_ID);
layout.addShowViewShortcut(IPageLayout.ID_RES_NAV);
layout.addShowViewShortcut(IPageLayout.ID_OUTLINE);
layout.addShowViewShortcut(IPageLayout.ID_PROBLEM_VIEW);
layout.addShowViewShortcut(IConsoleConstants.ID_CONSOLE_VIEW);
- layout.addShowViewShortcut("org.eclipse.wst.common.snippets.internal.ui.SnippetsView");
+ layout.addShowViewShortcut("org.eclipse.wst.common.snippets.internal.ui.SnippetsView"); //$NON-NLS-1$
}
private void addShortCutPerspective(IPageLayout layout) {
diff --git a/bundles/org.eclipse.wst.xsl.ui/src/org/eclipse/wst/xsl/ui/internal/preferences/IEditorConstants.java b/bundles/org.eclipse.wst.xsl.ui/src/org/eclipse/wst/xsl/ui/internal/preferences/IEditorConstants.java
index 4728620..0cd83dd 100644
--- a/bundles/org.eclipse.wst.xsl.ui/src/org/eclipse/wst/xsl/ui/internal/preferences/IEditorConstants.java
+++ b/bundles/org.eclipse.wst.xsl.ui/src/org/eclipse/wst/xsl/ui/internal/preferences/IEditorConstants.java
@@ -25,7 +25,7 @@
*
*/
-@SuppressWarnings("nls")
+@SuppressWarnings("nls") //$NON-NLS-1$
public interface IEditorConstants {
/** General Boolean Expression Type */
@@ -41,12 +41,12 @@
public static final String ET_UNSIGNED_INT = "unsignedInt"; //$NON-NLS-1$
/** Any expression type */
- public static final String ET_ANY = "any";
+ public static final String ET_ANY = "any"; //$NON-NLS-1$
/** A Boolean expression within a jointCondition */
- public static final String ET_JOIN = "joinCondition/boolean" ;
+ public static final String ET_JOIN = "joinCondition/boolean" ; //$NON-NLS-1$
/** A Boolean expression within a transitionCondition */
- public static final String ET_TRANSITION = "transitionCondition/boolean" ;
+ public static final String ET_TRANSITION = "transitionCondition/boolean" ; //$NON-NLS-1$
}
diff --git a/bundles/org.eclipse.wst.xsl.ui/src/org/eclipse/wst/xsl/ui/internal/preferences/MainPreferencePage.java b/bundles/org.eclipse.wst.xsl.ui/src/org/eclipse/wst/xsl/ui/internal/preferences/MainPreferencePage.java
index bdc355b..e027d16 100644
--- a/bundles/org.eclipse.wst.xsl.ui/src/org/eclipse/wst/xsl/ui/internal/preferences/MainPreferencePage.java
+++ b/bundles/org.eclipse.wst.xsl.ui/src/org/eclipse/wst/xsl/ui/internal/preferences/MainPreferencePage.java
@@ -56,7 +56,7 @@
ancestor.setLayout(layout);
Label label = new Label(ancestor, SWT.NONE);
- label.setText("Expand the tree to set preferences ");
+ label.setText(Messages.getString("MainPreferencePage.0")); //$NON-NLS-1$
// Label label = new Label(ancestor,SWT.NONE);
// label.setText("Resolve URI's relative to:");
diff --git a/bundles/org.eclipse.wst.xsl.ui/src/org/eclipse/wst/xsl/ui/internal/preferences/Messages.java b/bundles/org.eclipse.wst.xsl.ui/src/org/eclipse/wst/xsl/ui/internal/preferences/Messages.java
new file mode 100644
index 0000000..a1a62e2
--- /dev/null
+++ b/bundles/org.eclipse.wst.xsl.ui/src/org/eclipse/wst/xsl/ui/internal/preferences/Messages.java
@@ -0,0 +1,32 @@
+package org.eclipse.wst.xsl.ui.internal.preferences;
+
+import java.util.MissingResourceException;
+import java.util.ResourceBundle;
+
+/**
+ * TODO: Add Javadoc
+ * @author dcarver
+ *
+ */
+public class Messages {
+ private static final String BUNDLE_NAME = "org.eclipse.wst.xsl.ui.internal.preferences.messages"; //$NON-NLS-1$
+
+ private static final ResourceBundle RESOURCE_BUNDLE = ResourceBundle
+ .getBundle(BUNDLE_NAME);
+
+ private Messages() {
+ }
+
+ /**
+ * TODO: Add Javadoc
+ * @param key
+ * @return
+ */
+ public static String getString(String key) {
+ try {
+ return RESOURCE_BUNDLE.getString(key);
+ } catch (MissingResourceException e) {
+ return '!' + key + '!';
+ }
+ }
+}
diff --git a/bundles/org.eclipse.wst.xsl.ui/src/org/eclipse/wst/xsl/ui/internal/preferences/XSLTemplatePreferencePage.java b/bundles/org.eclipse.wst.xsl.ui/src/org/eclipse/wst/xsl/ui/internal/preferences/XSLTemplatePreferencePage.java
index f0448b6..38c5647 100644
--- a/bundles/org.eclipse.wst.xsl.ui/src/org/eclipse/wst/xsl/ui/internal/preferences/XSLTemplatePreferencePage.java
+++ b/bundles/org.eclipse.wst.xsl.ui/src/org/eclipse/wst/xsl/ui/internal/preferences/XSLTemplatePreferencePage.java
@@ -21,7 +21,7 @@
* @author dcarver
*
*/
-@SuppressWarnings("restriction")
+@SuppressWarnings("restriction") //$NON-NLS-1$
public class XSLTemplatePreferencePage extends XMLTemplatePreferencePage {
/**
diff --git a/bundles/org.eclipse.wst.xsl.ui/src/org/eclipse/wst/xsl/ui/internal/preferences/messages.properties b/bundles/org.eclipse.wst.xsl.ui/src/org/eclipse/wst/xsl/ui/internal/preferences/messages.properties
new file mode 100644
index 0000000..4e048e8
--- /dev/null
+++ b/bundles/org.eclipse.wst.xsl.ui/src/org/eclipse/wst/xsl/ui/internal/preferences/messages.properties
@@ -0,0 +1 @@
+MainPreferencePage.0=Expand the tree to set preferences
diff --git a/bundles/org.eclipse.wst.xsl.ui/src/org/eclipse/wst/xsl/ui/internal/validation/DelegatingSourceValidatorForXSL.java b/bundles/org.eclipse.wst.xsl.ui/src/org/eclipse/wst/xsl/ui/internal/validation/DelegatingSourceValidatorForXSL.java
index 1f557f1..67e20ec 100644
--- a/bundles/org.eclipse.wst.xsl.ui/src/org/eclipse/wst/xsl/ui/internal/validation/DelegatingSourceValidatorForXSL.java
+++ b/bundles/org.eclipse.wst.xsl.ui/src/org/eclipse/wst/xsl/ui/internal/validation/DelegatingSourceValidatorForXSL.java
@@ -20,7 +20,7 @@
*
*/
public class DelegatingSourceValidatorForXSL extends DelegatingSourceValidator {
- private final static String Id = "org.eclipse.wst.xsl.core.xsl";
+ private final static String Id = "org.eclipse.wst.xsl.core.xsl"; //$NON-NLS-1$
private Validator _validator;