|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Object | +--JShell
The JShell class is this program's main class and is called to run the program (i.e. java JShell). All subsequent class calls and methods are executed from this class. This class includes methods for retrieving and running commands that the user interactively enters at the JShell prompt.
| Constructor Summary | |
JShell()
Constructs a new JShell object by initializing the field myCommands with each type of supported command. |
|
| Method Summary | |
java.lang.String |
getCommand()
Retrieves the current command inputted interactively by user. |
static void |
main(java.lang.String[] args)
JShell's main function - calls getCommand() and
runCommand() to process and execute input line until
until user ends program via "logout". |
void |
runCommand(java.lang.String line)
Executes the current command. |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
public JShell()
myCommands with each type of supported command.
| Method Detail |
public java.lang.String getCommand()
public void runCommand(java.lang.String line)
line - input line to be processed.public static void main(java.lang.String[] args)
getCommand() and
runCommand() to process and execute input line until
until user ends program via "logout".
args - stores command line arguments for processing.
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||