diff options
author | Christian Mollekopf <chrigi_1@fastmail.fm> | 2016-07-07 22:23:49 +0200 |
---|---|---|
committer | Christian Mollekopf <chrigi_1@fastmail.fm> | 2016-07-07 22:23:49 +0200 |
commit | da2b049e248c1ad7efeb53685158a205335e4e36 (patch) | |
tree | 1e7e5e940e9b760b2108081b1d2f3879cebdb0ff /common/genericresource.h | |
parent | 9bcb822963fc96c94dbe7dcc4134dcd2dac454ff (diff) | |
download | sink-da2b049e248c1ad7efeb53685158a205335e4e36.tar.gz sink-da2b049e248c1ad7efeb53685158a205335e4e36.zip |
A new debug system.
Instead of a single #define as debug area the new system allows for an
identifier for each debug message with the structure component.area.
The component is a dot separated identifier of the runtime component,
such as the process or the plugin.
The area is the code component, and can be as such defined at
compiletime.
The idea of this system is that it becomes possible to i.e. look at the
output of all messages in the query subsystem of a specific resource
(something that happens in the client process, but in the
resource-specific subcomponent).
The new macros are supposed to be less likely to clash with other names,
hence the new names.
Diffstat (limited to 'common/genericresource.h')
-rw-r--r-- | common/genericresource.h | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/common/genericresource.h b/common/genericresource.h index 2254172..25892ca 100644 --- a/common/genericresource.h +++ b/common/genericresource.h | |||
@@ -40,6 +40,9 @@ class Synchronizer; | |||
40 | */ | 40 | */ |
41 | class SINK_EXPORT GenericResource : public Resource | 41 | class SINK_EXPORT GenericResource : public Resource |
42 | { | 42 | { |
43 | protected: | ||
44 | SINK_DEBUG_AREA("resource") | ||
45 | SINK_DEBUG_COMPONENT(mResourceInstanceIdentifier) | ||
43 | public: | 46 | public: |
44 | GenericResource(const QByteArray &resourceType, const QByteArray &resourceInstanceIdentifier, const QSharedPointer<Pipeline> &pipeline); | 47 | GenericResource(const QByteArray &resourceType, const QByteArray &resourceInstanceIdentifier, const QSharedPointer<Pipeline> &pipeline); |
45 | virtual ~GenericResource(); | 48 | virtual ~GenericResource(); |