Révision 3859

TXM/trunk/bundles/org.txm.statsengine.r.rcp/src/org/txm/statsengine/r/rcp/messages/messages.properties (revision 3859)
3 3
anErrorOccuredWhileGettingRWorkspaceInsanceColon=An error occurred while getting R workspace\: 
4 4
checkingRPackages=Checking R packages…
5 5
connectingRConsoleToRWorkspaceStdoutAndStderr=Connecting RConsole to RWorkspace stdout and stderr.
6
DefaultPackageRepository=Default package repository
6 7
eRRORColonREvalIsNotAListColon=** Error\: REval is not a list\: 
7 8
eRRORColonREvalListSizeIs0Colon=** Error\: REval list is empty\: 
8 9
eRRORColonRlistFirstElementIsNotREXPIntegerColon=** ERROR\: Rlist first element is not an REXPInteger\: 
9 10
errorWhileInitializingRConsoleColon=** Error while initializing the R console\: 
10 11
errorWhileInstallingPackageColon=** Error while installing package\: 
12
ErrorWhileInstallingRDependencyOfP0P1P2=Error while installing R dependency of {0} : {1} : {2}
13
ErrorWhileTEstingPackageP0=Error while testing package: {0}.
14
FailedToSendToR=Failed to send to R: 
11 15
installedSuccessfully=' installed successfully.
16
LogTheREvalCommandLines=Log the R eval command lines
12 17
necessaryPackagesAreReady=Necessary packages are ready.
18
P0HasBeenCopiedInTheP1RVariable=''{0}'' has been copied in the ''{1}'' R variable.
19
P0PackageNotInstalledErrorP1={0} package not installed. Error={1}.
20
P0WasNotTransferedToTheRWorkspace=** ''{0}'' was not transfered to the R workspace.
13 21
password=Password
14 22
pathToRBinary=Path to the R executable file
15 23
portDefaultIs6311=Port (default value\: 6311)
......
24 32
serverAddress=Server address
25 33
showEvalLogs=Showing R evaluation logs
26 34
somePackagesAreMissingSeeConsoleForDetails=Some packages are missing. See the console for details.
35
TheP0PackageIsNotInstalledTryingToInstallItNow=The '{0}' package is not installed. Trying to install it now...
36
TheP0PackageWasNotInstalledCorrecltyPleaseInstallItManually=The '{0}' package was not installed correctly. Please install it manually:\n * Run R\n * and execute 'install.packages("{1}"')
37
TryingToInstallTheP0DependencyOfP1Now=Trying to install the {0} dependency of {1} now...
27 38
theRStatEngineIsNotRunningTryingToReinstallThePackagesRServeFactoMineRTextometry=The R statistical engine is not accessible. Try to reinstall R packets needed for TXM (Rserve, FactoMineR, textometry...)
28 39
tXMCouldNotLoadTheFactoMineRRPackageTheCorrespondanceAnalysisClassificationCommandsWontBeAvailable=TXM could not load the 'FactoMineR' R package. The Correspondance analysis, Classification commands won't be available
29 40
tXMCouldNotLoadTheTextometryRPackageTheCooccurenceSpecificityAndProgressionCommandsWontBeAvailable=TXM could not load the 'textometry' R package. The Cooccurence, Specificity and Progression commands will not be available
30 41
tXMCouldNotReinstallRPackagesPleaseDoItManuallySeeManual=TXM could not re-install R packages. Please do it manually (see manual).
31 42
tXMNameP0SupSupRNameP1="TXM name {0} >> R name {1}
43
UpdateOfP0FailedCurrentVersionIsStillP1=Update of '{0}' failed (current version is still {1}). Warning: Windows users need to restart TXM.
44
UpdatingTheP0P1RPackageUpToVersionP2=Updating the '{0}' ({1}) R package up to version {2}...
32 45
useFileBasedRDataTransfert=Use file based R data transfert
33 46
user=User
TXM/trunk/bundles/org.txm.statsengine.r.rcp/src/org/txm/statsengine/r/rcp/messages/RUIMessages.java (revision 3859)
44 44
	public static String sendingToRWorkspaceColon; 
45 45
	public static String refreshingViews; 
46 46

  
47
	public static String connectingRConsoleToRWorkspaceStdoutAndStderr; 
48
	public static String errorWhileInitializingRConsoleColon; 
47
	public static String connectingRConsoleToRWorkspaceStdoutAndStderr;
48

  
49
	public static String DefaultPackageRepository; 
50
	public static String errorWhileInitializingRConsoleColon;
51

  
52
	public static String ErrorWhileInstallingRDependencyOfP0P1P2;
53

  
54
	public static String ErrorWhileTEstingPackageP0;
55

  
56
	public static String FailedToSendToR;
57

  
58
	public static String LogTheREvalCommandLines;
59

  
60
	public static String P0HasBeenCopiedInTheP1RVariable;
61

  
62
	public static String P0PackageNotInstalledErrorP1;
63

  
64
	public static String P0WasNotTransferedToTheRWorkspace; 
49 65
	public static String refreshVariables; 
50
	public static String showEvalLogs; 
66
	public static String showEvalLogs;
67

  
68
	public static String TheP0PackageIsNotInstalledTryingToInstallItNow;
69

  
70
	public static String TheP0PackageWasNotInstalledCorrecltyPleaseInstallItManually;
71

  
72
	public static String TryingToInstallTheP0DependencyOfP1Now; 
51 73
	public static String tXMNameP0SupSupRNameP1; 
52 74

  
75
	public static String UpdateOfP0FailedCurrentVersionIsStillP1;
76

  
77
	public static String UpdatingTheP0P1RPackageUpToVersionP2;
78

  
53 79
	static {
54 80
		// initialize resource bundle
55 81
		Utf8NLS.initializeMessages(BUNDLE_NAME, RUIMessages.class);
TXM/trunk/bundles/org.txm.statsengine.r.rcp/src/org/txm/statsengine/r/rcp/handlers/SendToRCommand.java (revision 3859)
86 86
					int delta = 100 / list.size();
87 87
					for (Object o : list) {
88 88
						if (o instanceof RResult) {
89
							Log.info(NLS.bind("''{0}'' has been copied in the ''{1}'' R variable.", ((RResult)o).toString(),  ((RResult)o).getRSymbol()));
89
							Log.info(NLS.bind(RUIMessages.P0HasBeenCopiedInTheP1RVariable, ((RResult)o).toString(),  ((RResult)o).getRSymbol()));
90 90
						} else if (o instanceof TXMResult) {
91 91
							try {
92 92
								monitor.subTask(RUIMessages.sendingToRWorkspaceColon + o);
93 93
								this.acquireSemaphore();
94 94
								String symbol = send((TXMResult) o);
95 95
								if (symbol == null) {
96
									Log.info(NLS.bind("** ''{0}'' was not transfered to the R workspace.", o));
96
									Log.info(NLS.bind(RUIMessages.P0WasNotTransferedToTheRWorkspace, o));
97 97
									this.releaseSemaphore();
98 98
									return Status.CANCEL_STATUS;
99 99
								}
100 100
								else {
101
									Log.info(NLS.bind("''{0}'' has been copied in the ''{1}'' R variable.", o.toString(), symbol));
101
									Log.info(NLS.bind(RUIMessages.P0HasBeenCopiedInTheP1RVariable, o.toString(), symbol));
102 102
								}
103 103
								this.releaseSemaphore();
104 104
								
......
106 106
								
107 107
							}
108 108
							catch (Exception e) {
109
								System.out.println("Failed to send to R: " + o);
109
								System.out.println(RUIMessages.FailedToSendToR + o);
110 110
								org.txm.utils.logger.Log.printStackTrace(e);
111 111
							}
112 112
						}
TXM/trunk/bundles/org.txm.statsengine.r.rcp/src/org/txm/statsengine/r/rcp/handlers/CheckRPackages.java (revision 3859)
117 117
				}
118 118
				catch (Exception e) {
119 119
					Log.printStackTrace(e);
120
					Log.severe(TXMCoreMessages.bind("{0} package not installed. Error={1}.", p, e));
120
					Log.severe(TXMCoreMessages.bind(RUIMessages.P0PackageNotInstalledErrorP1, p, e));
121 121
					ret = false;
122 122
				}
123 123
				
......
128 128
					}
129 129
					catch (Exception e) {
130 130
						Log.printStackTrace(e);
131
						Log.warning(TXMCoreMessages.bind("Error while testing package: {0}.", e));
131
						Log.warning(TXMCoreMessages.bind(RUIMessages.ErrorWhileTEstingPackageP0, e));
132 132
						ret = false;
133 133
					}
134 134
				}
135 135
				else { // package is not present, try installing it
136 136
					try {
137
						Log.info(TXMCoreMessages.bind("The '{0}' package is not installed. Trying to install it now...", p));
137
						Log.info(TXMCoreMessages.bind(RUIMessages.TheP0PackageIsNotInstalledTryingToInstallItNow, p));
138 138
						
139 139
						try {
140 140
							rw.eval("detach(\"package:" + p + "\", character.only = TRUE)"); //$NON-NLS-1$ //$NON-NLS-2$
......
146 146
						if (depends.containsKey(p)) {
147 147
							for (String dep : depends.get(p)) {
148 148
								try {
149
									Log.info(TXMCoreMessages.bind("Trying to install the {0} dependency of {1} now...", dep, p));
149
									Log.info(TXMCoreMessages.bind(RUIMessages.TryingToInstallTheP0DependencyOfP1Now, dep, p));
150 150
									rw.eval("install.packages(\"" + dep + "\", dependencies=TRUE, method=\"" + method + "\", repos=\"http://cran.rstudio.com\");"); //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
151 151
								}
152 152
								catch (Exception e) {
153
									Log.warning(TXMCoreMessages.bind("Error while installing R dependency of {0} : {1} : {2}", p, dep, e));
153
									Log.warning(TXMCoreMessages.bind(RUIMessages.ErrorWhileInstallingRDependencyOfP0P1P2, p, dep, e));
154 154
									Log.printStackTrace(e);
155 155
									ret = false;
156 156
								}
......
166 166
						}
167 167
						catch (Exception e) {
168 168
							Log.printStackTrace(e);
169
							Log.warning(TXMCoreMessages.bind("The '{0}' package was not installed correctly. Please install it manually:\n * Run R\n * and execute 'install.packages(\"{1}\"')", p, p));
169
							Log.warning(TXMCoreMessages.bind(RUIMessages.TheP0PackageWasNotInstalledCorrecltyPleaseInstallItManually, p, p));
170 170
							ret = false;
171 171
						}
172 172
					}
......
249 249
		// System.out.println("comp "+(packages.get(p))+" to "+(v));
250 250
		// System.out.println(packages.get(p).compareTo(v));
251 251
		if (packages.get(p).compareTo(currentVersion) > 0) {
252
			System.out.println(TXMCoreMessages.bind("Updating the '{0}' ({1}) R package up to version {2}...", p, currentVersion, packages.get(p)));
252
			System.out.println(TXMCoreMessages.bind(RUIMessages.UpdatingTheP0P1RPackageUpToVersionP2, p, currentVersion, packages.get(p)));
253 253
			
254 254
			try {
255 255
				rw.eval("detach(\"package:" + p + "\", character.only = TRUE)"); //$NON-NLS-1$ //$NON-NLS-2$
......
268 268
			} // reload it
269 269
			String newVersion = getVersion(rw, p);
270 270
			if (!newVersion.equals(packages.get(p))) {
271
				System.out.println(TXMCoreMessages.bind("Update of '{0}' failed (current version is still {1}). Warning: Windows users need to restart TXM.", p, newVersion));
271
				System.out.println(TXMCoreMessages.bind(RUIMessages.UpdateOfP0FailedCurrentVersionIsStillP1, p, newVersion));
272 272
				return false;
273 273
			}
274 274
		}
TXM/trunk/bundles/org.txm.statsengine.r.rcp/src/org/txm/statsengine/r/rcp/preferences/RPreferencePage.java (revision 3859)
149 149
		changeFieldStates(RPreferences.getInstance().getBoolean(RPreferences.REMOTE));
150 150
		
151 151
		
152
		addField(new BooleanFieldEditor(RPreferences.SHOW_EVAL_LOGS, "Log the R eval command lines", getFieldEditorParent()));
152
		addField(new BooleanFieldEditor(RPreferences.SHOW_EVAL_LOGS, RUIMessages.LogTheREvalCommandLines, getFieldEditorParent()));
153 153
		
154
		r_repos = new StringFieldEditor(RPreferences.DEFAULT_REPOS, "Defautl package repository", getFieldEditorParent());
154
		r_repos = new StringFieldEditor(RPreferences.DEFAULT_REPOS, RUIMessages.DefaultPackageRepository, getFieldEditorParent());
155 155
		addField(r_repos);
156 156
		
157 157
	}
......
213 213
			}
214 214
		}
215 215
		catch (Exception e) {
216
			System.err.println(NLS.bind(TXMUIMessages.failedToSavePreferencesColonP0, e));
216
			System.err.println(NLS.bind("", e)); //$NON-NLS-1$
217 217
		}
218 218
		return true;
219 219
	}

Formats disponibles : Unified diff