| java.lang.Object xtc.lang.jeannie.Debugger
Debugger | public class Debugger (Code) | | The Blink terminal debugger. This debugger internally uses jdb and gdb to
support the Jeannie source level debugging.
author: Byeongcheol (BK) Lee |
Inner Class :public enum DebugerControlStatus | |
Inner Class :public static class DebuggerResponse | |
Method Summary | |
boolean | IsDebuggerSwitchingInitialized() | synchronized void | changeDebugStatus(DebugerControlStatus newStatus) Switch to the new debugger state. | void | cont() Implement Blink "continue/cont" command. | void | err(String msg) Print an error message to the console. | DebugerControlStatus | getControlStatus() | void | j2n() Implements the j2c macro command. | void | jret() Implements jret macro command. | public static void | main(String[] args) The main method for the Blink debugger. | void | n2j() Implements c2j macro command. | void | out(String msg) Print a message to the console. | void | preparingDebuggerSwitching() Prepare jdb and gdb for j2c and c2j debugger switching. | void | printCommandHelp() Print the help message for the Blink command. | void | printStatus() Show the current Blink status. | void | run() Implement Blink "run" command. | Matcher | runAndWaitGDB(String msg, String expect) Send a message to the gdb process, and wait until the gdb sends back an
expected message. | Matcher | runAndWaitJDB(String msg, String expect) Send a message to the jdb , and wait until the jdb sends back an expected
message.
Parameters: msg - The message to send to the jdb. Parameters: expect - The message to be expected from the jdb. | DebuggerResponse | runAndWaitJDB(String msg, String[] expects) Send a message to the jdb, and wait for a number of expected messages from
the jdb.
Parameters: msg - The message to send to jdb. Parameters: expects - The list of expected message message. | Matcher | runGDBAndWaitJDB(String msg, String expect) Send a message to the gdb process, and wait until the jdb sends back an
expected message. | Matcher | runJDBAndWaitGDB(String msg, String expect) Send a message to the jdb process, and wait until the gdb sends back an
expected message. | synchronized void | sendUserMessage(String msg) Send a message to the currently chose debugger. |
allSlaveProcessLive | boolean allSlaveProcessLive(Code) | | This flag is set to be true at the beginning. If any slave process is dead,
this flag is set to be false, indicating that the current debugging session
should terminate.
|
debuggerCommand | final DebuggerCommand debuggerCommand(Code) | | The actual implementation of the blink macro command.
|
IsDebuggerSwitchingInitialized | boolean IsDebuggerSwitchingInitialized()(Code) | | Wheather or not the jdb/gdb switching is ready. |
changeDebugStatus | synchronized void changeDebugStatus(DebugerControlStatus newStatus)(Code) | | Switch to the new debugger state.
Parameters: newStatus - The requested new state. |
cont | void cont()(Code) | | Implement Blink "continue/cont" command.
|
err | void err(String msg)(Code) | | Print an error message to the console.
Parameters: msg - The error message to print. |
getControlStatus | DebugerControlStatus getControlStatus()(Code) | | The debugger control status. |
j2n | void j2n()(Code) | | Implements the j2c macro command. This will activate the gdb assuming that
the jdb has control over the debuggee.
|
jret | void jret()(Code) | | Implements jret macro command. If the current debugger nesting is jdb->gdb,
then this will resume the gdb break point, and the user input redirection
will be switched to the jdb. If the current debugger nesting is gdb->jdb,
this will resume the jdb break point, and the user input redirection will
be switched to the gdb.
|
main | public static void main(String[] args)(Code) | | The main method for the Blink debugger.
Parameters: args - The command line arguments. |
n2j | void n2j()(Code) | | Implements c2j macro command. This will activate the jdb assuming that gdb
has control over the debugee.
|
out | void out(String msg)(Code) | | Print a message to the console.
Parameters: msg - The message to print. |
preparingDebuggerSwitching | void preparingDebuggerSwitching()(Code) | | Prepare jdb and gdb for j2c and c2j debugger switching.
|
printCommandHelp | void printCommandHelp()(Code) | | Print the help message for the Blink command.
|
printStatus | void printStatus()(Code) | | Show the current Blink status.
|
run | void run()(Code) | | Implement Blink "run" command.
|
runAndWaitGDB | Matcher runAndWaitGDB(String msg, String expect) throws IOException(Code) | | Send a message to the gdb process, and wait until the gdb sends back an
expected message.
Parameters: msg - The message to send. Parameters: expect - The message to be expected from the gdb. |
runAndWaitJDB | Matcher runAndWaitJDB(String msg, String expect) throws IOException(Code) | | Send a message to the jdb , and wait until the jdb sends back an expected
message.
Parameters: msg - The message to send to the jdb. Parameters: expect - The message to be expected from the jdb. The matched result for the expected messsage. |
runAndWaitJDB | DebuggerResponse runAndWaitJDB(String msg, String[] expects) throws IOException(Code) | | Send a message to the jdb, and wait for a number of expected messages from
the jdb.
Parameters: msg - The message to send to jdb. Parameters: expects - The list of expected message message. The response from the jdb. |
runGDBAndWaitJDB | Matcher runGDBAndWaitJDB(String msg, String expect) throws IOException(Code) | | Send a message to the gdb process, and wait until the jdb sends back an
expected message.
Parameters: msg - The message to send. Parameters: expect - The list of the messages expected from the jdb. |
runJDBAndWaitGDB | Matcher runJDBAndWaitGDB(String msg, String expect) throws IOException(Code) | | Send a message to the jdb process, and wait until the gdb sends back an
expected message.
Parameters: msg - The message to send. Parameters: expect - The message to be expected from the slave process. |
sendUserMessage | synchronized void sendUserMessage(String msg) throws IOException(Code) | | Send a message to the currently chose debugger.
Parameters: msg - The message. |
|
|