Skip to main content
summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMichael Valenta2003-08-22 15:03:26 +0000
committerMichael Valenta2003-08-22 15:03:26 +0000
commite4ffe8579699a0985a9cdc081d22dea9fa1dd767 (patch)
tree0e325adfb546ed6590ad8a31cc1336f3196e778d /examples
parentd68feff4cd14f087c4af714b88948502505d30ed (diff)
downloadeclipse.platform.team-e4ffe8579699a0985a9cdc081d22dea9fa1dd767.tar.gz
eclipse.platform.team-e4ffe8579699a0985a9cdc081d22dea9fa1dd767.tar.xz
eclipse.platform.team-e4ffe8579699a0985a9cdc081d22dea9fa1dd767.zip
NLS Pass
Diffstat (limited to 'examples')
-rw-r--r--examples/org.eclipse.team.examples.filesystem/src/org/eclipse/team/examples/filesystem/FileModificationValidator.java2
-rw-r--r--examples/org.eclipse.team.examples.filesystem/src/org/eclipse/team/examples/filesystem/FileSystemPlugin.java6
-rw-r--r--examples/org.eclipse.team.examples.filesystem/src/org/eclipse/team/examples/filesystem/FileSystemProvider.java4
-rw-r--r--examples/org.eclipse.team.examples.filesystem/src/org/eclipse/team/examples/filesystem/FileSystemRemoteResource.java5
-rw-r--r--examples/org.eclipse.team.examples.filesystem/src/org/eclipse/team/examples/filesystem/FileSystemSimpleAccessOperations.java9
-rw-r--r--examples/org.eclipse.team.examples.filesystem/src/org/eclipse/team/examples/filesystem/Policy.java4
-rw-r--r--examples/org.eclipse.team.examples.filesystem/src/org/eclipse/team/examples/filesystem/StreamUtil.java2
-rw-r--r--examples/org.eclipse.team.examples.filesystem/src/org/eclipse/team/examples/filesystem/messages.properties5
-rw-r--r--examples/org.eclipse.team.examples.filesystem/src/org/eclipse/team/examples/filesystem/ui/ConfigurationWizard.java8
-rw-r--r--examples/org.eclipse.team.examples.filesystem/src/org/eclipse/team/examples/filesystem/ui/DisconnectAction.java2
-rw-r--r--examples/org.eclipse.team.examples.filesystem/src/org/eclipse/team/examples/filesystem/ui/FileSystemMainPage.java6
11 files changed, 29 insertions, 24 deletions
diff --git a/examples/org.eclipse.team.examples.filesystem/src/org/eclipse/team/examples/filesystem/FileModificationValidator.java b/examples/org.eclipse.team.examples.filesystem/src/org/eclipse/team/examples/filesystem/FileModificationValidator.java
index 040ea09d5..6020049bd 100644
--- a/examples/org.eclipse.team.examples.filesystem/src/org/eclipse/team/examples/filesystem/FileModificationValidator.java
+++ b/examples/org.eclipse.team.examples.filesystem/src/org/eclipse/team/examples/filesystem/FileModificationValidator.java
@@ -30,7 +30,7 @@ import org.eclipse.team.internal.core.simpleAccess.SimpleAccessOperations;
*/
public final class FileModificationValidator implements IFileModificationValidator {
//Used to avoid creating multiple copies of the OK status:
- private static final IStatus OK_STATUS = new Status(Status.OK, FileSystemPlugin.ID, Status.OK, Policy.bind("ok"), null);
+ private static final IStatus OK_STATUS = new Status(Status.OK, FileSystemPlugin.ID, Status.OK, Policy.bind("ok"), null); //$NON-NLS-1$
private RepositoryProvider provider;
private SimpleAccessOperations operations;
diff --git a/examples/org.eclipse.team.examples.filesystem/src/org/eclipse/team/examples/filesystem/FileSystemPlugin.java b/examples/org.eclipse.team.examples.filesystem/src/org/eclipse/team/examples/filesystem/FileSystemPlugin.java
index 3a62e7180..040f24c3e 100644
--- a/examples/org.eclipse.team.examples.filesystem/src/org/eclipse/team/examples/filesystem/FileSystemPlugin.java
+++ b/examples/org.eclipse.team.examples.filesystem/src/org/eclipse/team/examples/filesystem/FileSystemPlugin.java
@@ -34,12 +34,12 @@ public class FileSystemPlugin extends AbstractUIPlugin {
/**
* This is the ID of the plugin as defined in the plugin.xml
*/
- public static final String ID = "org.eclipse.team.examples.filesystem";
+ public static final String ID = "org.eclipse.team.examples.filesystem"; //$NON-NLS-1$
/**
* This is the provider ID of the plugin as defined in the plugin.xml
*/
- public static final String PROVIDER_ID = ID + ".FileSystemProvider";
+ public static final String PROVIDER_ID = ID + ".FileSystemProvider"; //$NON-NLS-1$
// This static field will hold the singleton instance of the plugin class
private static FileSystemPlugin plugin;
@@ -63,7 +63,7 @@ public class FileSystemPlugin extends AbstractUIPlugin {
*/
public void startup() throws CoreException {
// localize the string bindings used by the plugins (in order to provide NLS support)
- Policy.localize("org.eclipse.team.examples.filesystem.messages");
+ Policy.localize("org.eclipse.team.examples.filesystem.messages"); //$NON-NLS-1$
}
/**
diff --git a/examples/org.eclipse.team.examples.filesystem/src/org/eclipse/team/examples/filesystem/FileSystemProvider.java b/examples/org.eclipse.team.examples.filesystem/src/org/eclipse/team/examples/filesystem/FileSystemProvider.java
index 310b648d3..2fae985be 100644
--- a/examples/org.eclipse.team.examples.filesystem/src/org/eclipse/team/examples/filesystem/FileSystemProvider.java
+++ b/examples/org.eclipse.team.examples.filesystem/src/org/eclipse/team/examples/filesystem/FileSystemProvider.java
@@ -54,7 +54,7 @@ public class FileSystemProvider extends RepositoryProvider {
private IPath root;
// The QualifiedName that is used to persist the location accross workspace as a persistant property on a resource
- private static QualifiedName FILESYSTEM_REPO_LOC = new QualifiedName(FileSystemPlugin.ID, "disk_location");
+ private static QualifiedName FILESYSTEM_REPO_LOC = new QualifiedName(FileSystemPlugin.ID, "disk_location"); //$NON-NLS-1$
/**
* Create a new FileSystemProvider.
@@ -110,7 +110,7 @@ public class FileSystemProvider extends RepositoryProvider {
// ensure that the location is a folder (if it exists)
File file = new File(location);
if (file.exists() && !file.isDirectory()) {
- throw new TeamException(Policy.bind("FileSystemProvider.mustBeFolder", location));
+ throw new TeamException(Policy.bind("FileSystemProvider.mustBeFolder", location)); //$NON-NLS-1$
}
// record the location as a persistant property so it will be remembered across platform invokations
diff --git a/examples/org.eclipse.team.examples.filesystem/src/org/eclipse/team/examples/filesystem/FileSystemRemoteResource.java b/examples/org.eclipse.team.examples.filesystem/src/org/eclipse/team/examples/filesystem/FileSystemRemoteResource.java
index f8c8761a1..5e4b929a8 100644
--- a/examples/org.eclipse.team.examples.filesystem/src/org/eclipse/team/examples/filesystem/FileSystemRemoteResource.java
+++ b/examples/org.eclipse.team.examples.filesystem/src/org/eclipse/team/examples/filesystem/FileSystemRemoteResource.java
@@ -23,6 +23,7 @@ import org.eclipse.core.runtime.IProgressMonitor;
import org.eclipse.core.runtime.Platform;
import org.eclipse.team.core.TeamException;
import org.eclipse.team.core.sync.IRemoteResource;
+import org.eclipse.team.examples.filesystem.Policy;
/**
* Class represents a handle to a <code>java.io.File</code> that conforms to
@@ -67,7 +68,7 @@ public class FileSystemRemoteResource implements IRemoteResource {
*/
public InputStream getContents(IProgressMonitor progress) throws TeamException {
if (isContainer())
- throw new TeamException("This resource is a container so it cannot have data.");
+ throw new TeamException(Policy.bind("FileSystemRemoteResource.0")); //$NON-NLS-1$
try {
return new FileInputStream(ioFile);
} catch (FileNotFoundException e) {
@@ -107,7 +108,7 @@ public class FileSystemRemoteResource implements IRemoteResource {
public IRemoteResource[] members(IProgressMonitor progress) throws TeamException {
// Make sure we have a container
if (!isContainer())
- throw new TeamException(Policy.bind("RemoteResource.mustBeFolder", ioFile.getName()));
+ throw new TeamException(Policy.bind("RemoteResource.mustBeFolder", ioFile.getName())); //$NON-NLS-1$
// convert the File children to remote resource children
File[] members = ioFile.listFiles();
diff --git a/examples/org.eclipse.team.examples.filesystem/src/org/eclipse/team/examples/filesystem/FileSystemSimpleAccessOperations.java b/examples/org.eclipse.team.examples.filesystem/src/org/eclipse/team/examples/filesystem/FileSystemSimpleAccessOperations.java
index db1f054bb..87852220a 100644
--- a/examples/org.eclipse.team.examples.filesystem/src/org/eclipse/team/examples/filesystem/FileSystemSimpleAccessOperations.java
+++ b/examples/org.eclipse.team.examples.filesystem/src/org/eclipse/team/examples/filesystem/FileSystemSimpleAccessOperations.java
@@ -24,6 +24,7 @@ import org.eclipse.core.runtime.IProgressMonitor;
import org.eclipse.team.core.TeamException;
import org.eclipse.team.core.sync.IRemoteResource;
import org.eclipse.team.internal.core.simpleAccess.SimpleAccessOperations;
+import org.eclipse.team.examples.filesystem.Policy;
/**
* SimpleAccessOperations is not part of the Team API. We use it here because it provides
@@ -61,7 +62,7 @@ public class FileSystemSimpleAccessOperations implements SimpleAccessOperations
public void get(IResource[] resources, int depth, IProgressMonitor progress) throws TeamException {
// ensure the progress monitor is not null
progress = Policy.monitorFor(progress);
- progress.beginTask(Policy.bind("GetAction.working"), resources.length);
+ progress.beginTask(Policy.bind("GetAction.working"), resources.length); //$NON-NLS-1$
for (int i = 0; i < resources.length; i++) {
Policy.checkCanceled(progress);
IPath rootdir = provider.getRoot();
@@ -140,7 +141,7 @@ public class FileSystemSimpleAccessOperations implements SimpleAccessOperations
*/
public void checkout(IResource[] resources, int depth, IProgressMonitor progress) throws TeamException {
progress = Policy.monitorFor(progress);
- progress.beginTask("Checking resources out...", resources.length);
+ progress.beginTask(Policy.bind("FileSystemSimpleAccessOperations.1"), resources.length); //$NON-NLS-1$
IPath rootdir = provider.getRoot();
for (int i = 0; i < resources.length; i++) {
Policy.checkCanceled(progress);
@@ -179,7 +180,7 @@ public class FileSystemSimpleAccessOperations implements SimpleAccessOperations
public void checkin(IResource[] resources, int depth, IProgressMonitor progress) throws TeamException {
// ensure the progress monitor is not null
progress = Policy.monitorFor(progress);
- progress.beginTask(Policy.bind("PutAction.working"), resources.length);
+ progress.beginTask(Policy.bind("PutAction.working"), resources.length); //$NON-NLS-1$
for (int i = 0; i < resources.length; i++) {
Policy.checkCanceled(progress);
IPath rootdir = provider.getRoot();
@@ -243,7 +244,7 @@ public class FileSystemSimpleAccessOperations implements SimpleAccessOperations
*/
public void uncheckout(IResource[] resources, int depth, IProgressMonitor progress) throws TeamException {
progress = Policy.monitorFor(progress);
- progress.beginTask("Re-locking resources...", resources.length);
+ progress.beginTask(Policy.bind("FileSystemSimpleAccessOperations.3"), resources.length); //$NON-NLS-1$
IPath rootdir = provider.getRoot();
for (int i = 0; i < resources.length; i++) {
Policy.checkCanceled(progress);
diff --git a/examples/org.eclipse.team.examples.filesystem/src/org/eclipse/team/examples/filesystem/Policy.java b/examples/org.eclipse.team.examples.filesystem/src/org/eclipse/team/examples/filesystem/Policy.java
index 00220dcdd..cfb2db53a 100644
--- a/examples/org.eclipse.team.examples.filesystem/src/org/eclipse/team/examples/filesystem/Policy.java
+++ b/examples/org.eclipse.team.examples.filesystem/src/org/eclipse/team/examples/filesystem/Policy.java
@@ -59,7 +59,7 @@ public class Policy {
} catch (MissingResourceException e) {
return key;
} catch (NullPointerException e) {
- return "!" + key + "!";
+ return "!" + key + "!"; //$NON-NLS-1$ //$NON-NLS-2$
}
}
@@ -73,7 +73,7 @@ public class Policy {
} catch (MissingResourceException e) {
return key;
} catch (NullPointerException e) {
- return "!" + key + "!";
+ return "!" + key + "!"; //$NON-NLS-1$ //$NON-NLS-2$
}
}
diff --git a/examples/org.eclipse.team.examples.filesystem/src/org/eclipse/team/examples/filesystem/StreamUtil.java b/examples/org.eclipse.team.examples.filesystem/src/org/eclipse/team/examples/filesystem/StreamUtil.java
index 0e392c269..f39f21743 100644
--- a/examples/org.eclipse.team.examples.filesystem/src/org/eclipse/team/examples/filesystem/StreamUtil.java
+++ b/examples/org.eclipse.team.examples.filesystem/src/org/eclipse/team/examples/filesystem/StreamUtil.java
@@ -45,7 +45,7 @@ public class StreamUtil {
bytesCopied = bytesCopied + read;
progress.subTask(
Policy.bind(
- "filetransfer.monitor",
+ "filetransfer.monitor", //$NON-NLS-1$
new Object[] { title, new Long(bytesCopied / 1024), kilobytesEstimate }));
}
diff --git a/examples/org.eclipse.team.examples.filesystem/src/org/eclipse/team/examples/filesystem/messages.properties b/examples/org.eclipse.team.examples.filesystem/src/org/eclipse/team/examples/filesystem/messages.properties
index 832eb7cd2..ccb68c1c3 100644
--- a/examples/org.eclipse.team.examples.filesystem/src/org/eclipse/team/examples/filesystem/messages.properties
+++ b/examples/org.eclipse.team.examples.filesystem/src/org/eclipse/team/examples/filesystem/messages.properties
@@ -35,4 +35,7 @@ ReplaceAction.working=Replacing resources...
ReplaceAction.problemMessage=A problem occured replacing the resources.
FileSystemProvider.mustBeFolder=Target location ''{0}'' is a file and must be a folder.
-RemoteResource.mustBeFolder=Resource ''{0}'' is a file so it cannot have entries \ No newline at end of file
+RemoteResource.mustBeFolder=Resource ''{0}'' is a file so it cannot have entries
+FileSystemRemoteResource.0=This resource is a container so it cannot have data.
+FileSystemSimpleAccessOperations.1=Checking resources out...
+FileSystemSimpleAccessOperations.3=Re-locking resources...
diff --git a/examples/org.eclipse.team.examples.filesystem/src/org/eclipse/team/examples/filesystem/ui/ConfigurationWizard.java b/examples/org.eclipse.team.examples.filesystem/src/org/eclipse/team/examples/filesystem/ui/ConfigurationWizard.java
index 090f23818..bab78242b 100644
--- a/examples/org.eclipse.team.examples.filesystem/src/org/eclipse/team/examples/filesystem/ui/ConfigurationWizard.java
+++ b/examples/org.eclipse.team.examples.filesystem/src/org/eclipse/team/examples/filesystem/ui/ConfigurationWizard.java
@@ -57,8 +57,8 @@ public class ConfigurationWizard extends Wizard implements IConfigurationWizard
public void addPages() {
mainPage = new FileSystemMainPage(
"FileSystemMainPage", //$NON-NLS-1$
- Policy.bind("ConfigurationWizard.name"),
- Policy.bind("ConfigurationWizard.description"),
+ Policy.bind("ConfigurationWizard.name"), //$NON-NLS-1$
+ Policy.bind("ConfigurationWizard.description"), //$NON-NLS-1$
null);
addPage(mainPage);
}
@@ -77,8 +77,8 @@ public class ConfigurationWizard extends Wizard implements IConfigurationWizard
} catch (TeamException e) {
ErrorDialog.openError(
getShell(),
- Policy.bind("ConfigurationWizard.errorMapping"),
- Policy.bind("ConfigurationWizard.error"),
+ Policy.bind("ConfigurationWizard.errorMapping"), //$NON-NLS-1$
+ Policy.bind("ConfigurationWizard.error"), //$NON-NLS-1$
e.getStatus());
return false;
}
diff --git a/examples/org.eclipse.team.examples.filesystem/src/org/eclipse/team/examples/filesystem/ui/DisconnectAction.java b/examples/org.eclipse.team.examples.filesystem/src/org/eclipse/team/examples/filesystem/ui/DisconnectAction.java
index 52cc47c52..6fc051cdd 100644
--- a/examples/org.eclipse.team.examples.filesystem/src/org/eclipse/team/examples/filesystem/ui/DisconnectAction.java
+++ b/examples/org.eclipse.team.examples.filesystem/src/org/eclipse/team/examples/filesystem/ui/DisconnectAction.java
@@ -33,7 +33,7 @@ public class DisconnectAction extends TeamAction {
RepositoryProvider.unmap(projects[i]);
}
} catch (TeamException e) {
- ErrorDialog.openError(getShell(), Policy.bind("DisconnectAction.errorTitle"), null, e.getStatus());
+ ErrorDialog.openError(getShell(), Policy.bind("DisconnectAction.errorTitle"), null, e.getStatus()); //$NON-NLS-1$
}
}
diff --git a/examples/org.eclipse.team.examples.filesystem/src/org/eclipse/team/examples/filesystem/ui/FileSystemMainPage.java b/examples/org.eclipse.team.examples.filesystem/src/org/eclipse/team/examples/filesystem/ui/FileSystemMainPage.java
index 97bea03f7..219ac80fc 100644
--- a/examples/org.eclipse.team.examples.filesystem/src/org/eclipse/team/examples/filesystem/ui/FileSystemMainPage.java
+++ b/examples/org.eclipse.team.examples.filesystem/src/org/eclipse/team/examples/filesystem/ui/FileSystemMainPage.java
@@ -208,7 +208,7 @@ public class FileSystemMainPage extends WizardPage {
setControl(composite);
Label label = new Label(composite, SWT.NULL);
- label.setText(Policy.bind("FileSystemMainPage.location"));
+ label.setText(Policy.bind("FileSystemMainPage.location")); //$NON-NLS-1$
label.setLayoutData(new GridData());
locationCombo = createEditableCombo(composite);
@@ -225,7 +225,7 @@ public class FileSystemMainPage extends WizardPage {
new Label(composite, SWT.NULL);
Button browse = new Button(composite, SWT.NULL);
browse.setLayoutData(new GridData(GridData.HORIZONTAL_ALIGN_END));
- browse.setText(Policy.bind("FileSystemMainPage.browseDir"));
+ browse.setText(Policy.bind("FileSystemMainPage.browseDir")); //$NON-NLS-1$
browse.addListener(SWT.Selection, new Listener() {
public void handleEvent(Event event) {
DirectoryDialog d = new DirectoryDialog(getShell());
@@ -290,7 +290,7 @@ public class FileSystemMainPage extends WizardPage {
} else {
File file = new File(location);
if(!file.exists() || !file.isDirectory()) {
- setErrorMessage(Policy.bind("FileSystemMainPage.notValidLocation"));
+ setErrorMessage(Policy.bind("FileSystemMainPage.notValidLocation")); //$NON-NLS-1$
setPageComplete(false);
return;
}

Back to the top