/debugger/qluadebuggeragent_p.h

https://code.google.com/p/qtlua/ · C Header · 61 lines · 34 code · 8 blank · 19 comment · 0 complexity · 278427e14dde2d164a5d18455d4a99c9 MD5 · raw file

  1. /* QtLua -- Lua bindings for Qt
  2. Copyright (C) 2011, Jarek Pelczar
  3. This library is free software; you can redistribute it and/or
  4. modify it under the terms of the GNU Lesser General Public
  5. License as published by the Free Software Foundation; either
  6. version 3 of the License, or (at your option) any later version.
  7. This library is distributed in the hope that it will be useful,
  8. but WITHOUT ANY WARRANTY; without even the implied warranty of
  9. MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
  10. Lesser General Public License for more details.
  11. You should have received a copy of the GNU Lesser General
  12. Public License along with this library; if not, write to the
  13. Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
  14. Boston, MA 02110-1301 USA
  15. */
  16. #ifndef QLUADEBUGGERAGENT_P_H
  17. #define QLUADEBUGGERAGENT_P_H
  18. #include <QObject>
  19. #include "qluascriptengineagent.h"
  20. class QLuaScriptDebugger;
  21. class QLuaDebuggerAgent : public QObject, public QLuaScriptEngineAgent
  22. {
  23. Q_OBJECT
  24. public:
  25. explicit QLuaDebuggerAgent(QLuaScriptDebugger *parent, QLuaScriptEngine * engine);
  26. ~QLuaDebuggerAgent();
  27. virtual void contextPop();
  28. virtual void contextPush();
  29. virtual void exceptionCatch(qint64 scriptId, const QLuaScriptValue& exception);
  30. virtual void exceptionThrow(qint64 scriptId, const QLuaScriptValue& exception, bool hasHandler);
  31. virtual void functionEntry(qint64 scriptId);
  32. virtual void functionExit(qint64 scriptId, const QLuaScriptValue & returnValue);
  33. virtual void positionChange(qint64 scriptId, int lineNumber, int columnNumber);
  34. virtual void scriptLoad(qint64 id, const QString & program, const QString& fileName, int baseLineNumber);
  35. virtual void scriptUnload(qint64 id);
  36. signals:
  37. void _p_contextPop();
  38. void _p_contextPush();
  39. void _p_exceptionCatch(qint64, const QLuaScriptValue&);
  40. void _p_exceptionThrow(qint64, const QLuaScriptValue&, bool);
  41. void _p_functionEntry(qint64);
  42. void _p_functionExit(qint64, const QLuaScriptValue&);
  43. void _p_positionChange(qint64, int, int);
  44. void _p_scriptLoad(qint64, QString, QString, int);
  45. void _p_scriptUnload(qint64);
  46. private:
  47. QLuaScriptDebugger * m_debugger;
  48. };
  49. #endif // QLUADEBUGGERAGENT_P_H