Beispiel #1
0
        public EmonicInterpreter(DebuggerConfiguration config,
		                         DebuggerOptions options)
            : base(true,config,options)
        {
            DebuggerEngine = new EmonicDebuggerEngine(this);
            thisReference = this;
        }
Beispiel #2
0
 public EmonicInterpreter(DebuggerConfiguration config,
                          DebuggerOptions options)
     : base(true, config, options)
 {
     DebuggerEngine = new EmonicDebuggerEngine(this);
     thisReference  = this;
 }
Beispiel #3
0
        public int Break(string file, int lineNumber)
        {
            EmonicLineInterpreter.AddCmd("break " + file + ":" + lineNumber);
            int result = EmonicInterpreter.GetBreakpointNumber();

            return(result);
        }
Beispiel #4
0
 public EmonicInterpreter.backtraceData Backtrace(bool execute)
 {
     if (execute)
     {
         EmonicInterpreter.backtraceList.Clear();                 // remove all previous elements from the list
         EmonicLineInterpreter.AddCmd("backtrace");
     }
     EmonicInterpreter.backtraceData btd = EmonicInterpreter.GetNextBacktraceLine();
     return(btd);
 }
Beispiel #5
0
 public EmonicInterpreter.threadData GetThreads(bool execute)
 {
     if (execute)
     {
         EmonicInterpreter.threadList.Clear();                 // remove all previous elements from the list
         EmonicLineInterpreter.AddCmd("show threads");
     }
     EmonicInterpreter.threadData td = EmonicInterpreter.GetNextThreadLine();
     return(td);
 }
Beispiel #6
0
        public string GetParameters()
        {
            if (!EmonicInterpreter.IsCurrentThreadStopped())
            {
                // would block if current thread is not stopped!
                return("--");
            }
            EmonicLineInterpreter.AddCmd("show parameters");
            string result = EmonicInterpreter.GetParamsOutput();

            return(result);
        }
Beispiel #7
0
 public EmonicInterpreter.printData Print(string variableName)
 {
     if (!EmonicInterpreter.IsCurrentThreadStopped())
     {
         // would block if current thread is not stopped!
         EmonicInterpreter.printData error = new EmonicInterpreter.printData();
         error.type = error.varValue = error.varNames = "";
         return(error);
     }
     EmonicLineInterpreter.AddCmd("print " + variableName);
     EmonicInterpreter.printData pd = EmonicInterpreter.GetPrintOutput();
     return(pd);
 }
Beispiel #8
0
        public string PtypeFieldsOnly(string className, bool staticOnly)
        {
            if (!EmonicInterpreter.IsCurrentThreadStopped())
            {
                // would block if current thread is not stopped!
                return("--");
            }
            EmonicLineInterpreter.AddCmd("ptype " + className);
            string result;

            if (staticOnly)
            {
                result = EmonicInterpreter.GetPTypeOutputStaticOnly();
            }
            else
            {
                result = EmonicInterpreter.GetPTypeOutput();
            }
            return(result);
        }
Beispiel #9
0
 public EmonicDebuggerEngine(EmonicInterpreter interpreter)
     : base(interpreter)
 {
     RegisterCommand("background", typeof(BackgroundThreadCommand));
     RegisterCommand("backtrace", typeof(EmonicBacktraceCommand));
     RegisterCommand("break", typeof(EmonicBreakCommand));
     RegisterCommand("delete", typeof(BreakpointDeleteCommand));
     RegisterCommand("disable", typeof(BreakpointDisableCommand));
     RegisterCommand("enable", typeof(BreakpointEnableCommand));
     RegisterCommand("finish", typeof(FinishCommand));
     RegisterCommand("frame", typeof(SelectFrameCommand));
     RegisterCommand("next", typeof(NextCommand));
     RegisterCommand("print", typeof(EmonicPrintExpressionCommand));
     RegisterCommand("ptype", typeof(EmonicPrintTypeCommand));
     RegisterCommand("quit", typeof(EmonicQuitCommand));
     RegisterCommand("set", typeof(SetCommand));
     RegisterCommand("show", typeof(EmonicShowCommand));
     RegisterCommand("start", typeof(StartCommand));
     RegisterCommand("step", typeof(StepCommand));
     RegisterCommand("stop", typeof(StopThreadCommand));
     RegisterCommand("thread", typeof(SelectThreadCommand));
 }
Beispiel #10
0
 public EmonicInterpreter.eventData GetNextEvent()
 {
     return(EmonicInterpreter.GetNextEvent());
 }
Beispiel #11
0
 public EmonicDebuggerEngine(EmonicInterpreter interpreter)
     : base(interpreter)
 {
     RegisterCommand ("background", typeof (BackgroundThreadCommand));
     RegisterCommand ("backtrace", typeof (EmonicBacktraceCommand));
     RegisterCommand ("break", typeof (EmonicBreakCommand));
     RegisterCommand ("delete", typeof (BreakpointDeleteCommand));
     RegisterCommand ("disable", typeof (BreakpointDisableCommand));
     RegisterCommand ("enable", typeof (BreakpointEnableCommand));
     RegisterCommand ("finish", typeof (FinishCommand));
     RegisterCommand ("frame", typeof (SelectFrameCommand));
     RegisterCommand ("next", typeof (NextCommand));
     RegisterCommand ("print", typeof (EmonicPrintExpressionCommand));
     RegisterCommand ("ptype", typeof (EmonicPrintTypeCommand));
     RegisterCommand ("quit", typeof (EmonicQuitCommand));
     RegisterCommand ("set", typeof (SetCommand));
     RegisterCommand ("show", typeof (EmonicShowCommand));
     RegisterCommand ("start", typeof (StartCommand));
     RegisterCommand ("step", typeof (StepCommand));
     RegisterCommand ("stop", typeof (StopThreadCommand));
     RegisterCommand ("thread", typeof (SelectThreadCommand));
 }