Skip to content

Commit

Permalink
Restore the old eval(String command) method
Browse files Browse the repository at this point in the history
  • Loading branch information
Valentin Georgiev committed Apr 10, 2013
1 parent 1dc572f commit f0514e4
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 9 deletions.
Expand Up @@ -31,7 +31,7 @@ public interface IRBusinessManager extends IBioclipseManager {
public String eval(String command, RServi myRServi);

@Recorded
public String evalS(String command, RServi servi);
public String eval(String command);

public String getStatus();

Expand Down
Expand Up @@ -109,7 +109,7 @@ public RBusinessManager() throws LoginException, NoSuchElementException {
working = false;
status = e.getMessage();
}
// rservi = getInitR("Rconsole");
rservi = getInitR("Rconsole");
}

public RServi getInitR(String task) {
Expand Down Expand Up @@ -143,14 +143,15 @@ public RServi getInitR(String task) {
}
return rservi;
}

public String evalS(String command, RServi servi) {

/**
* The old eval method that can be called without RServi
* @param command
* @return result
*/
public String eval(String command) {
String result;
if (servi == null) {
result = eval(command, rservi);
} else {
result = eval(command, servi);
}
return result;
}
/**
Expand Down
Expand Up @@ -115,7 +115,7 @@ protected IStatus run( IProgressMonitor pm ) {
}
}
try {
result[0] = r.evalS( nextAction[0].getCommand(), servi );
result[0] = r.eval( nextAction[0].getCommand(), servi );
}
catch (Throwable t) {
LogUtils.debugTrace( logger, t );
Expand Down

0 comments on commit f0514e4

Please sign in to comment.