QGIS API Documentation 3.99.0-Master (26c88405ac0)
Loading...
Searching...
No Matches
qgsabstractprofilesource.h
Go to the documentation of this file.
1/***************************************************************************
2 qgsabstractprofilesource.h
3 ---------------
4 begin : March 2022
5 copyright : (C) 2022 by Nyall Dawson
6 email : nyall dot dawson at gmail dot com
7 ***************************************************************************/
8
9/***************************************************************************
10 * *
11 * This program is free software; you can redistribute it and/or modify *
12 * it under the terms of the GNU General Public License as published by *
13 * the Free Software Foundation; either version 2 of the License, or *
14 * (at your option) any later version. *
15 * *
16 ***************************************************************************/
17#ifndef QGSABSTRACTPROFILESOURCE_H
18#define QGSABSTRACTPROFILESOURCE_H
19
20#include "qgis_core.h"
21#include "qgis_sip.h"
22
25
26#include <QUuid>
27
34class CORE_EXPORT QgsAbstractProfileSource
35{
36
37 public:
38
40
50
59 virtual QString profileSourceId() const { return mSourceId; }; // TODO QGIS 5.0: Make it pure virtual
60
68 virtual QString profileSourceName() const { return QString(); }; // TODO QGIS 5.0: Make it pure virtual
69
70 private:
71 QString mSourceId = QUuid::createUuid().toString(); // Support legacy sources with a uuid
72
73};
74
75#endif // QGSABSTRACTPROFILESOURCE_H
Abstract base class for objects which generate elevation profiles.
Interface for classes which can generate elevation profiles.
virtual QString profileSourceId() const
Returns a unique identifier for this profile source.
virtual QgsAbstractProfileGenerator * createProfileGenerator(const QgsProfileRequest &request)=0
Given a profile request, returns a new profile generator ready for generating elevation profiles.
virtual ~QgsAbstractProfileSource()
virtual QString profileSourceName() const
Returns a name for displaying this profile source in the elevation profile layer tree.
Encapsulates properties and constraints relating to fetching elevation profiles from different source...
#define SIP_FACTORY
Definition qgis_sip.h:84