Groovy Documentation

org.codehaus.groovy.tools.shell
[Groovy] Class Groovysh

java.lang.Object
  org.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).

Authors:
Jason Dillon
Version:
\$Id\$


Field Summary
 
Fields inherited from class Shell
log
 
Property Summary
BufferManager buffers

Closure defaultErrorHook

Closure defaultResultHook

Closure errorHook

java.lang.String evictedLine

jline.History history

boolean historyFull

java.util.List imports

Interpreter interp

Parser parser

Closure resultHook

InteractiveShellRunner runner

 
Constructor Summary
Groovysh(java.lang.ClassLoader classLoader, Binding binding, IO io, Closure registrar)

Groovysh(java.lang.ClassLoader classLoader, Binding binding, IO io)

Groovysh(Binding binding, IO io)

Groovysh(IO io)

Groovysh()

 
Method Summary
java.lang.Object execute(java.lang.String line)

Execute a single line, where the line may be a command or Groovy code (complete or incomplete).

protected java.lang.Object executeCommand(java.lang.String line)

java.io.File getUserStateDirectory()

java.lang.String renderPrompt()

int run(java.lang.String[] args)

int run(java.lang.String commandLine)

 
Methods inherited from class Shell
execute, findCommand, isExecutable, leftShift, leftShift, parseLine, register
 

Property Detail

buffers

final BufferManager buffers


defaultErrorHook

final Closure defaultErrorHook


defaultResultHook

final Closure defaultResultHook


errorHook

Closure errorHook


evictedLine

java.lang.String evictedLine


history

jline.History history


historyFull

boolean historyFull


imports

final java.util.List imports


interp

final Interpreter interp


parser

final Parser parser


resultHook

Closure resultHook


runner

InteractiveShellRunner runner


 
Constructor Detail

Groovysh

Groovysh(java.lang.ClassLoader classLoader, Binding binding, IO io, Closure registrar)


Groovysh

Groovysh(java.lang.ClassLoader classLoader, Binding binding, IO io)


Groovysh

Groovysh(Binding binding, IO io)


Groovysh

Groovysh(IO io)


Groovysh

Groovysh()


 
Method Detail

execute

java.lang.Object execute(java.lang.String line)
Execute a single line, where the line may be a command or Groovy code (complete or incomplete).


executeCommand

protected java.lang.Object executeCommand(java.lang.String line)


getUserStateDirectory

java.io.File getUserStateDirectory()


renderPrompt

java.lang.String renderPrompt()


run

int run(java.lang.String[] args)


run

int run(java.lang.String commandLine)


 

Groovy Documentation