Skip to content
Permalink
Browse files

Base class processing feedback object forwards messages to message log

  • Loading branch information
nyalldawson committed Aug 13, 2017
1 parent 913bf64 commit f7ae07126e85d0bc93d15518489d9a1b93bfdf52
Showing with 6 additions and 5 deletions.
  1. +6 −5 src/core/processing/qgsprocessingfeedback.h
@@ -20,6 +20,7 @@

#include "qgis_core.h"
#include "qgsfeedback.h"
#include "qgsmessagelog.h"

/**
* \class QgsProcessingFeedback
@@ -49,7 +50,7 @@ class CORE_EXPORT QgsProcessingFeedback : public QgsFeedback
* Reports that the algorithm encountered an error which prevented it
* from successfully executing.
*/
virtual void reportError( const QString &error ) { Q_UNUSED( error ); }
virtual void reportError( const QString &error ) { QgsMessageLog::logMessage( error ); }

/**
* Pushes a general informational message from the algorithm. This can
@@ -59,7 +60,7 @@ class CORE_EXPORT QgsProcessingFeedback : public QgsFeedback
* \see pushDebugInfo()
* \see pushConsoleInfo()
*/
virtual void pushInfo( const QString &info ) { Q_UNUSED( info ); }
virtual void pushInfo( const QString &info ) { QgsMessageLog::logMessage( info ); }

/**
* Pushes an informational message containing a command from the algorithm.
@@ -69,7 +70,7 @@ class CORE_EXPORT QgsProcessingFeedback : public QgsFeedback
* \see pushDebugInfo()
* \see pushConsoleInfo()
*/
virtual void pushCommandInfo( const QString &info ) { Q_UNUSED( info ); }
virtual void pushCommandInfo( const QString &info ) { QgsMessageLog::logMessage( info ); }

/**
* Pushes an informational message containing debugging helpers from
@@ -78,7 +79,7 @@ class CORE_EXPORT QgsProcessingFeedback : public QgsFeedback
* \see pushCommandInfo()
* \see pushConsoleInfo()
*/
virtual void pushDebugInfo( const QString &info ) { Q_UNUSED( info ); }
virtual void pushDebugInfo( const QString &info ) { QgsMessageLog::logMessage( info ); }

/**
* Pushes a console feedback message from the algorithm. This is used to
@@ -87,7 +88,7 @@ class CORE_EXPORT QgsProcessingFeedback : public QgsFeedback
* \see pushDebugInfo()
* \see pushCommandInfo()
*/
virtual void pushConsoleInfo( const QString &info ) { Q_UNUSED( info ); }
virtual void pushConsoleInfo( const QString &info ) { QgsMessageLog::logMessage( info ); }

};

0 comments on commit f7ae071

Please sign in to comment.
You can’t perform that action at this time.