File tree Expand file tree Collapse file tree 4 files changed +11
-9
lines changed
Expand file tree Collapse file tree 4 files changed +11
-9
lines changed Original file line number Diff line number Diff line change @@ -62,9 +62,8 @@ class QgsService
6262
6363 /**
6464 * Execute the requests and set result in QgsServerRequest
65- * @param request a QgsServerRequest instance
66- * @param response a QgsServerResponse instance
6765 */
68- virtual void executeRequest( const QgsServerRequest& request, QgsServerResponse& response ) = 0;
66+ virtual void executeRequest( const QgsServerRequest& request, QgsServerResponse& response,
67+ QgsProject* project = nullptr ) = 0;
6968};
7069
Original file line number Diff line number Diff line change @@ -63,13 +63,13 @@ class QgsServiceRegistry
6363 void registerService( QgsService* service /Transfer/ );
6464
6565 /**
66- * Unregister service from its name and version
66+ * Unregister service from its name and version
6767 *
6868 * @param name the tame of the service
6969 * @param version (optional) the specific version to unload
7070 * @return the number of unregstered services
7171 *
72- * If the version is not specified then all versions from the specified service
72+ * If the version is not specified then all versions from the specified service
7373 * are unloaded
7474 */
7575 int unregisterService( const QString& name, const QString& version = QString() );
Original file line number Diff line number Diff line change 2424#include " qgsserverrequest.h"
2525#include " qgsserverresponse.h"
2626
27+ class QgsProject ;
28+
2729/* *
2830 * \ingroup server
2931 * QgsService
@@ -61,10 +63,9 @@ class SERVER_EXPORT QgsService
6163
6264 /* *
6365 * Execute the requests and set result in QgsServerRequest
64- * @param request a QgsServerRequest instance
65- * @param response a QgsServerResponse instance
6666 */
67- virtual void executeRequest ( const QgsServerRequest& request, QgsServerResponse& response ) = 0;
67+ virtual void executeRequest ( const QgsServerRequest& request, QgsServerResponse& response,
68+ QgsProject* project = nullptr ) = 0;
6869};
6970
7071#endif
Original file line number Diff line number Diff line change @@ -31,8 +31,10 @@ class SampleService: public QgsService
3131 return method == QgsServerRequest::GetMethod;
3232 }
3333
34- void executeRequest ( const QgsServerRequest& request, QgsServerResponse& response )
34+ void executeRequest ( const QgsServerRequest& request, QgsServerResponse& response,
35+ QgsProject* project )
3536 {
37+ Q_UNUSED ( project );
3638 Q_UNUSED ( request );
3739 QgsDebugMsg ( " SampleService::executeRequest called" );
3840 response.write ( QString ( " Hello world from myService" ) );
You can’t perform that action at this time.
0 commit comments