|
Groovy 2.2.0-beta-1 | |||||||
FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | PROPERTY | CONSTR | METHOD | DETAIL: FIELD | PROPERTY | CONSTR | METHOD |
java.lang.Objectorg.codehaus.groovy.tools.shell.Shell
org.codehaus.groovy.tools.shell.Groovysh
class Groovysh extends Shell
An interactive shell for evaluating Groovy code from the command-line (aka. groovysh).
Field Summary | |
---|---|
static String |
AUTOINDENT_PREFERENCE_KEY
|
Fields inherited from class Shell | |
---|---|
log |
Property Summary | |
---|---|
BufferManager |
buffers
|
groovy.lang.Closure |
defaultErrorHook
|
groovy.lang.Closure |
defaultResultHook
|
groovy.lang.Closure |
errorHook
|
String |
evictedLine
|
jline.console.history.FileHistory |
history
|
boolean |
historyFull
|
List |
imports
|
int |
indentSize
|
Interpreter |
interp
|
PackageHelper |
packageHelper
|
Parser |
parser
|
groovy.lang.Closure |
resultHook
|
InteractiveShellRunner |
runner
|
Constructor Summary | |
Groovysh(ClassLoader classLoader, groovy.lang.Binding binding, org.codehaus.groovy.tools.shell.IO io, groovy.lang.Closure registrar)
|
|
Groovysh(ClassLoader classLoader, groovy.lang.Binding binding, org.codehaus.groovy.tools.shell.IO io)
|
|
Groovysh(groovy.lang.Binding binding, org.codehaus.groovy.tools.shell.IO io)
|
|
Groovysh(org.codehaus.groovy.tools.shell.IO io)
|
|
Groovysh()
|
Method Summary | |
---|---|
void
|
displayBuffer(List buffer)
Display the given buffer. |
Object
|
execute(String line)
Execute a single line, where the line may be a command or Groovy code (complete or incomplete). |
protected Object
|
executeCommand(String line)
|
String
|
getIndentPrefix()
Calculate probably desired indentation based on parenthesis balance and last char, as well as what the user used last as indentation. |
File
|
getUserStateDirectory()
|
String
|
renderPrompt()
|
int
|
run(String[] args)
|
int
|
run(String commandLine)
|
Methods inherited from class Shell | |
---|---|
execute, findCommand, isExecutable, leftShift, leftShift, parseLine, register |
Field Detail |
---|
public static final String AUTOINDENT_PREFERENCE_KEY
Property Detail |
---|
final BufferManager buffers
final groovy.lang.Closure defaultErrorHook
final groovy.lang.Closure defaultResultHook
groovy.lang.Closure errorHook
String evictedLine
jline.console.history.FileHistory history
boolean historyFull
final List imports
int indentSize
final Interpreter interp
PackageHelper packageHelper
final Parser parser
groovy.lang.Closure resultHook
InteractiveShellRunner runner
Constructor Detail |
---|
Groovysh(ClassLoader classLoader, groovy.lang.Binding binding, org.codehaus.groovy.tools.shell.IO io, groovy.lang.Closure registrar)
Groovysh(ClassLoader classLoader, groovy.lang.Binding binding, org.codehaus.groovy.tools.shell.IO io)
Groovysh(groovy.lang.Binding binding, org.codehaus.groovy.tools.shell.IO io)
Groovysh(org.codehaus.groovy.tools.shell.IO io)
Groovysh()
Method Detail |
---|
void displayBuffer(List buffer)
Object execute(String line)
protected Object executeCommand(String line)
String getIndentPrefix()
File getUserStateDirectory()
String renderPrompt()
int run(String[] args)
int run(String commandLine)
Copyright © 2003-2013 The Codehaus. All rights reserved.