Public Member Functions | |
JConsole () | |
Creates a new instance of JConsole. | |
void | initialize () |
InputStream | getInputStream () |
void | cut () |
void | paste () |
void | setCaretPosition (int position) |
void | actionPerformed (ActionEvent e) |
Invoked when an action occurs. | |
void | keyPressed (KeyEvent e) |
Invoked when a key has been pressed. | |
void | keyReleased (KeyEvent e) |
Invoked when a key has been released. | |
void | keyTyped (KeyEvent e) |
Invoked when a key has been typed. | |
void | caretUpdate (CaretEvent e) |
Invoked when the caret changes position. | |
void | mouseClicked (MouseEvent e) |
Invoked when the mouse button has been clicked (pressed and released) on a component. | |
void | mouseEntered (MouseEvent e) |
Invoked when the mouse enters a component. | |
void | mouseExited (MouseEvent e) |
Invoked when the mouse exits a component. | |
void | mousePressed (MouseEvent e) |
Invoked when a mouse button has been pressed on a component. | |
void | mouseReleased (MouseEvent e) |
Invoked when a mouse button has been released on a component. | |
void | propertyChange (PropertyChangeEvent evt) |
This method gets called when a bound property is changed. | |
void | addActionListener (ActionListener al) |
void | removeActionListener (ActionListener al) |
void | addNameCompletionListener (NameCompletionListener tl) |
void | removeNameCompletionListener (NameCompletionListener tl) |
void | resetCommandStart () |
Prints the prompt and prepairs for input. | |
void | append (String string) |
String | getPrompt () |
void | setPrompt (String prompt) |
String | getPostPrompt () |
void | setPostPrompt (String postPrompt) |
String | toString () |
void | println (String string) |
void | print (String string) |
void | println () |
void | println (Object object) |
void | print (Object object) |
Protected Member Functions | |
void | initComponents () |
void | ensureCaretPosition () |
void | nameCompletionEvent () |
String | completeInline (String part, List l) |
Do as much completing as possible inline... | |
void | enter () |
void | dispatchEvent (String cmd) |
void | historyUp () |
void | historyDown () |
void | showHistoryLine () |
Protected Attributes | |
JPopupMenu | mPopup |
The popup menu. | |
String | sPrompt |
The prompt. | |
String | sPostPrompt |
A String that is printed after the prompt, but can be edited by the user. | |
char | cEnterChar = '\n' |
The char that signifies "enter". | |
Vector | vListeners = new Vector() |
The action listeners. | |
Vector | nameListeners = new Vector() |
The name completion listeners. | |
Vector | vHistory = new Vector() |
Holds the history. | |
AbstractDocument | doc |
The Document for the output. | |
Package Functions | |
String | replaceRange (Object s, int start, int end) |
Private Member Functions | |
void | showMenu (MouseEvent e) |
void | insert (String string, int pos) |
String | getCmd () |
Private Attributes | |
int | lineStartPos = 0 |
The place where the current command entry line starts. | |
int | startPos = 0 |
The place where the current command starts. | |
int | currPos = 0 |
The current text entry point. | |
int | historyPos = 0 |
Current history position. | |
String | curCmd |
Holds the current command. | |
Static Private Attributes | |
final String | CUT = "Cut" |
final String | COPY = "Copy" |
final String | PASTE = "Paste" |
It generates ActionEvents whenever the user presses the Enter key and TextEvents when the name completion key is pressed. It has a history, a prompt and that's about it. More complex things should be done by whatever understands the input! It can also print text in lots of different ways and icons. It is based very loosely on the JConsole class in the BeanShell scripting framework, but is extremely modified.
Definition at line 25 of file JConsole.java.
|
Invoked when a key has been pressed. See the class description for KeyEvent for a definition of a key pressed event. Definition at line 137 of file JConsole.java. References GuiComponents.Console.JConsole.doc, and GuiComponents.Console.JConsole.startPos. |
|
Invoked when a key has been released. See the class description for KeyEvent for a definition of a key released event. Definition at line 185 of file JConsole.java. |
|
Invoked when a key has been typed. See the class description for KeyEvent for a definition of a key typed event. Definition at line 193 of file JConsole.java. References GuiComponents.Console.JConsole.cEnterChar. |
|
This method gets called when a bound property is changed.
Definition at line 271 of file JConsole.java. References GuiComponents.Console.JConsole.mPopup. |
|
Prints the prompt and prepairs for input. Should be called by a client if they want to force a new command. Definition at line 363 of file JConsole.java. References GuiComponents.Console.JConsole.currPos, GuiComponents.Console.JConsole.doc, GuiComponents.Console.JConsole.lineStartPos, GuiComponents.Console.JConsole.sPostPrompt, GuiComponents.Console.JConsole.sPrompt, and GuiComponents.Console.JConsole.startPos. |