QGIS API Documentation  3.4.15-Madeira (e83d02e274)
qgsprojectbadlayerhandler.h
Go to the documentation of this file.
1 /***************************************************************************
2  qgsprojectbadlayerhandler.h - QgsProjectBadLayerHandler
3 
4  ---------------------
5  begin : 22.10.2016
6  copyright : (C) 2016 by Matthias Kuhn
7  email : [email protected]
8  ***************************************************************************
9  * *
10  * This program is free software; you can redistribute it and/or modify *
11  * it under the terms of the GNU General Public License as published by *
12  * the Free Software Foundation; either version 2 of the License, or *
13  * (at your option) any later version. *
14  * *
15  ***************************************************************************/
16 #ifndef QGSPROJECTBADLAYERHANDLER_H
17 #define QGSPROJECTBADLAYERHANDLER_H
18 
19 #include <QDomNode>
20 
21 #include "qgis_core.h"
22 
27 class CORE_EXPORT QgsProjectBadLayerHandler
28 {
29  public:
30 
42  virtual void handleBadLayers( const QList<QDomNode> &layers );
43  virtual ~QgsProjectBadLayerHandler() = default;
44 
45 
46  protected:
47 
49  enum DataType
50  {
53  IS_BOGUS
54  };
55 
58  {
62  IS_Unknown
63  };
64 
65 
73  DataType dataType( const QDomNode &layerNode );
74 
84  QString dataSource( const QDomNode &layerNode );
85 
102  ProviderType providerType( const QDomNode &layerNode );
103 
109  void setDataSource( QDomNode &layerNode, const QString &dataSource );
110 };
111 
112 #endif // QGSPROJECTBADLAYERHANDLER_H
DataType
file data representation
ProviderType
the flavors for data storage
Interface for classes that handle missing layer files when reading project file.