2014-02-15 18:49:35 +05:30
|
|
|
#pragma once
|
|
|
|
|
2014-02-16 17:22:35 +05:30
|
|
|
#include "BaseExternalTool.h"
|
2014-02-15 18:49:35 +05:30
|
|
|
|
2014-02-16 02:56:44 +05:30
|
|
|
class BaseInstance;
|
2014-02-15 18:49:35 +05:30
|
|
|
class SettingsObject;
|
2015-01-28 03:01:07 +05:30
|
|
|
class BaseProcess;
|
2014-02-15 22:45:41 +05:30
|
|
|
class QProcess;
|
2014-02-15 18:49:35 +05:30
|
|
|
|
2014-02-16 15:16:14 +05:30
|
|
|
class BaseProfiler : public BaseExternalTool
|
2014-02-15 18:49:35 +05:30
|
|
|
{
|
|
|
|
Q_OBJECT
|
|
|
|
public:
|
2014-03-30 23:41:05 +05:30
|
|
|
explicit BaseProfiler(InstancePtr instance, QObject *parent = 0);
|
2014-02-15 18:49:35 +05:30
|
|
|
|
|
|
|
public
|
|
|
|
slots:
|
2015-01-28 03:01:07 +05:30
|
|
|
void beginProfiling(BaseProcess *process);
|
2014-02-16 13:24:52 +05:30
|
|
|
void abortProfiling();
|
2014-02-15 18:49:35 +05:30
|
|
|
|
|
|
|
protected:
|
2014-02-16 13:24:52 +05:30
|
|
|
QProcess *m_profilerProcess;
|
2014-02-15 18:49:35 +05:30
|
|
|
|
2015-01-28 03:01:07 +05:30
|
|
|
virtual void beginProfilingImpl(BaseProcess *process) = 0;
|
2014-02-16 13:24:52 +05:30
|
|
|
virtual void abortProfilingImpl();
|
2014-02-15 18:49:35 +05:30
|
|
|
|
|
|
|
signals:
|
|
|
|
void readyToLaunch(const QString &message);
|
2014-02-16 13:24:52 +05:30
|
|
|
void abortLaunch(const QString &message);
|
2014-02-15 18:49:35 +05:30
|
|
|
};
|
|
|
|
|
2014-02-16 15:16:14 +05:30
|
|
|
class BaseProfilerFactory : public BaseExternalToolFactory
|
2014-02-15 18:49:35 +05:30
|
|
|
{
|
|
|
|
public:
|
2014-03-30 23:41:05 +05:30
|
|
|
virtual BaseProfiler *createProfiler(InstancePtr instance, QObject *parent = 0);
|
2014-02-15 18:49:35 +05:30
|
|
|
};
|