fix history issue

This commit is contained in:
Jarred Li
2012-05-31 13:17:44 +08:00
parent cbe61e1d6f
commit befa5f12c5
2 changed files with 13 additions and 24 deletions

View File

@@ -558,9 +558,7 @@ public abstract class JLineShell extends AbstractShell implements CommandMarker,
*
* @return history file name
*/
protected String getHistoryFileName() {
return Constant.HISTORY_FILE_NAME;
}
abstract protected String getHistoryFileName();
/**
* get prompt text from provider. The provider has highest order
@@ -568,14 +566,20 @@ public abstract class JLineShell extends AbstractShell implements CommandMarker,
*
* @return prompt text
*/
protected String getPromptText() {
return Constant.COMMAND_LINE_PROMPT;
}
abstract protected String getPromptText();
protected String getProductName() {
return Constant.PRODUCT_NAME;
}
/**
* get product name
*
* @return Product Name
*/
abstract protected String getProductName();
/**
* get version information
*
* @return Version
*/
protected String getVersion() {
return VersionUtils.versionInfo();
}

View File

@@ -43,7 +43,6 @@ public class JLineShellComponent extends JLineShell implements Lifecycle {
private String version;
private String welcomeMessage;
private int historySize;
// Fields
private ExecutionStrategy executionStrategy = new SimpleExecutionStrategy(); //ProcessManagerHostedExecutionStrategy is not what i think we need outside of Roo.
@@ -206,20 +205,6 @@ public class JLineShellComponent extends JLineShell implements Lifecycle {
public void setPrintBanner(boolean printBanner) {
this.printBanner = printBanner;
}
/**
* @return the historySize
*/
public int getHistorySize() {
return historySize;
}
/**
* @param historySize the historySize to set
*/
public void setHistorySize(int historySize) {
this.historySize = historySize;
}
protected String getProductName() {
return productName;