org.apache.geronimo.gshell.console
Class JLineConsole

java.lang.Object
  extended by org.apache.geronimo.gshell.console.Console
      extended by org.apache.geronimo.gshell.console.JLineConsole
All Implemented Interfaces:
Runnable

public class JLineConsole
extends Console

Support for running a Shell using the JLine library.

Version:
$Rev: 574416 $ $Date: 2007-09-10 17:49:15 -0700 (Mon, 10 Sep 2007) $

Nested Class Summary
 
Nested classes/interfaces inherited from class org.apache.geronimo.gshell.console.Console
Console.ErrorHandler, Console.Executor, Console.Prompter
 
Field Summary
 
Fields inherited from class org.apache.geronimo.gshell.console.Console
autoTrim, breakOnNull, errorHandler, executor, ignoreEmpty, log, prompter, running
 
Constructor Summary
JLineConsole(Console.Executor executor, IO io, jline.Terminal terminal)
           
 
Method Summary
protected  String readLine(String prompt)
           
 void run()
           
 void setHistory(jline.History history)
           
 void setHistoryFile(File file)
           
 
Methods inherited from class org.apache.geronimo.gshell.console.Console
getErrorHandler, getExecutor, getPrompter, isAutoTrim, isBreakOnNull, isIgnoreEmpty, isRunning, setAutoTrim, setBreakOnNull, setErrorHandler, setExecutor, setIgnoreEmpty, setPrompter, setRunning, work
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

JLineConsole

public JLineConsole(Console.Executor executor,
                    IO io,
                    jline.Terminal terminal)
             throws IOException
Throws:
IOException
Method Detail

run

public void run()
Specified by:
run in interface Runnable
Overrides:
run in class Console

setHistory

public void setHistory(jline.History history)

setHistoryFile

public void setHistoryFile(File file)
                    throws IOException
Throws:
IOException

readLine

protected String readLine(String prompt)
                   throws IOException
Specified by:
readLine in class Console
Throws:
IOException


Copyright © 2003-2007 Apache Software Foundation. All Rights Reserved.