Qt 4.8
Public Functions | Protected Functions | List of all members
QScriptEngineDebuggerFrontend Class Reference

The QScriptEngineDebuggerFrontend class provides an in-process debugger frontend. More...

#include <qscriptenginedebuggerfrontend_p.h>

Inheritance diagram for QScriptEngineDebuggerFrontend:
QScriptDebuggerFrontend QScriptDebuggerCommandSchedulerInterface

Public Functions

void attachTo (QScriptEngine *engine)
 Attaches this front-end to the given engine. More...
 
QScriptDebuggerBackendbackend () const
 
void detach ()
 Detaches this front-end from the current script engine. More...
 
 QScriptEngineDebuggerFrontend ()
 
QScriptValue traceFunction () const
 
 ~QScriptEngineDebuggerFrontend ()
 
- Public Functions inherited from QScriptDebuggerFrontend
QScriptDebuggerEventHandlerInterfaceeventHandler () const
 
 QScriptDebuggerFrontend ()
 
int scheduleCommand (const QScriptDebuggerCommand &command, QScriptDebuggerResponseHandlerInterface *responseHandler)
 Schedules the given command for execution by this front-end, and returns a unique identifier associated with this command. More...
 
int scheduledCommandCount () const
 
void setEventHandler (QScriptDebuggerEventHandlerInterface *eventHandler)
 
virtual ~QScriptDebuggerFrontend ()
 
- Public Functions inherited from QScriptDebuggerCommandSchedulerInterface
virtual ~QScriptDebuggerCommandSchedulerInterface ()
 

Protected Functions

void processCommand (int id, const QScriptDebuggerCommand &command)
 
- Protected Functions inherited from QScriptDebuggerFrontend
void notifyCommandFinished (int id, const QScriptDebuggerResponse &response)
 Subclasses should call this function when the command identified by the given id has finished and produced the given response. More...
 
bool notifyEvent (const QScriptDebuggerEvent &event)
 Subclasses should call this function when the given event is received from the back-end. More...
 
 QScriptDebuggerFrontend (QScriptDebuggerFrontendPrivate &dd)
 

Additional Inherited Members

- Protected Variables inherited from QScriptDebuggerFrontend
QScopedPointer< QScriptDebuggerFrontendPrivated_ptr
 

Detailed Description

The QScriptEngineDebuggerFrontend class provides an in-process debugger frontend.

Since
4.5
Warning
This function is not part of the public interface.

This type of frontend is used when the QScriptEngine being debugged lives in the same process as the debugger.

Call the attachTo() function to attach to an engine.

Definition at line 65 of file qscriptenginedebuggerfrontend_p.h.

Constructors and Destructors

◆ QScriptEngineDebuggerFrontend()

QScriptEngineDebuggerFrontend::QScriptEngineDebuggerFrontend ( )

◆ ~QScriptEngineDebuggerFrontend()

QScriptEngineDebuggerFrontend::~QScriptEngineDebuggerFrontend ( )

Definition at line 289 of file qscriptenginedebuggerfrontend.cpp.

290 {
291  detach();
292 }
void detach()
Detaches this front-end from the current script engine.

Functions

◆ attachTo()

void QScriptEngineDebuggerFrontend::attachTo ( QScriptEngine engine)

Attaches this front-end to the given engine.

Definition at line 297 of file qscriptenginedebuggerfrontend.cpp.

298 {
300  if (d->backend)
301  d->backend->detach();
302  else
303  d->backend = new QScriptEngineDebuggerBackend(d);
304  d->backend->attachTo(engine);
305 }
double d
Definition: qnumeric_p.h:62
#define Q_D(Class)
Definition: qglobal.h:2482
The QScriptEngineDebuggerFrontend class provides an in-process debugger frontend. ...

◆ backend()

QScriptDebuggerBackend * QScriptEngineDebuggerFrontend::backend ( ) const

Definition at line 325 of file qscriptenginedebuggerfrontend.cpp.

326 {
328  return d->backend;
329 }
double d
Definition: qnumeric_p.h:62
#define Q_D(Class)
Definition: qglobal.h:2482
The QScriptEngineDebuggerFrontend class provides an in-process debugger frontend. ...

◆ detach()

void QScriptEngineDebuggerFrontend::detach ( )

Detaches this front-end from the current script engine.

Definition at line 310 of file qscriptenginedebuggerfrontend.cpp.

Referenced by ~QScriptEngineDebuggerFrontend().

311 {
313  if (d->backend)
314  d->backend->detach();
315 }
double d
Definition: qnumeric_p.h:62
#define Q_D(Class)
Definition: qglobal.h:2482
The QScriptEngineDebuggerFrontend class provides an in-process debugger frontend. ...

◆ processCommand()

void QScriptEngineDebuggerFrontend::processCommand ( int  id,
const QScriptDebuggerCommand command 
)
protectedvirtual
Warning
This function is not part of the public interface.

Implements QScriptDebuggerFrontend.

Definition at line 334 of file qscriptenginedebuggerfrontend.cpp.

335 {
337  Q_ASSERT(d->backend != 0);
338  d->backend->processCommand(id, command);
339 }
double d
Definition: qnumeric_p.h:62
#define Q_ASSERT(cond)
Definition: qglobal.h:1823
#define Q_D(Class)
Definition: qglobal.h:2482
The QScriptEngineDebuggerFrontend class provides an in-process debugger frontend. ...

◆ traceFunction()

QScriptValue QScriptEngineDebuggerFrontend::traceFunction ( ) const

Definition at line 317 of file qscriptenginedebuggerfrontend.cpp.

318 {
320  if (d->backend)
321  d->backend->traceFunction();
322  return QScriptValue();
323 }
double d
Definition: qnumeric_p.h:62
#define Q_D(Class)
Definition: qglobal.h:2482
The QScriptEngineDebuggerFrontend class provides an in-process debugger frontend. ...
The QScriptValue class acts as a container for the Qt Script data types.
Definition: qscriptvalue.h:57

The documentation for this class was generated from the following files: