QGIS API Documentation
4.3.0-Master (52aa6503bed)
Toggle main menu visibility
Loading...
Searching...
No Matches
src
core
externalstorage
qgsexternalstorageregistry.h
Go to the documentation of this file.
1
/***************************************************************************
2
qgsexternalstorageregistry.h
3
--------------------------------------
4
Date : March 2021
5
Copyright : (C) 2021 by Julien Cabieces
6
Email : julien dot cabieces at oslandia dot com
7
***************************************************************************
8
* *
9
* This program is free software; you can redistribute it and/or modify *
10
* it under the terms of the GNU General Public License as published by *
11
* the Free Software Foundation; either version 2 of the License, or *
12
* (at your option) any later version. *
13
* *
14
***************************************************************************/
15
16
#ifndef QGSEXTERNALSTORAGEREGISTRY_H
17
#define QGSEXTERNALSTORAGEREGISTRY_H
18
19
#include "qgis_core.h"
20
#include "
qgis_sip.h
"
21
22
#include <QHash>
23
#include <QList>
24
25
class
QgsExternalStorage
;
26
36
class
CORE_EXPORT
QgsExternalStorageRegistry
37
{
38
public
:
42
QgsExternalStorageRegistry
();
43
44
~QgsExternalStorageRegistry
();
45
50
QgsExternalStorage
*
externalStorageFromType
(
const
QString &type )
const
;
51
55
QList<QgsExternalStorage *>
externalStorages
()
const
;
56
60
void
registerExternalStorage
(
QgsExternalStorage
*storage
SIP_TRANSFER
);
61
65
void
unregisterExternalStorage
(
QgsExternalStorage
*storage );
66
67
private
:
68
QList< QgsExternalStorage * > mBackends;
69
};
70
71
#endif
// QGSEXTERNALSTORAGEREGISTRY_H
QgsExternalStorageRegistry::externalStorageFromType
QgsExternalStorage * externalStorageFromType(const QString &type) const
Returns external storage implementation if the storage type matches one.
Definition
qgsexternalstorageregistry.cpp:34
QgsExternalStorageRegistry::registerExternalStorage
void registerExternalStorage(QgsExternalStorage *storage)
Registers a storage backend and takes ownership of it.
Definition
qgsexternalstorageregistry.cpp:46
QgsExternalStorageRegistry::externalStorages
QList< QgsExternalStorage * > externalStorages() const
Returns a list of registered project storage implementations.
Definition
qgsexternalstorageregistry.cpp:41
QgsExternalStorageRegistry::QgsExternalStorageRegistry
QgsExternalStorageRegistry()
Constructor - creates a registry of external storage backends.
Definition
qgsexternalstorageregistry.cpp:22
QgsExternalStorageRegistry::unregisterExternalStorage
void unregisterExternalStorage(QgsExternalStorage *storage)
Unregisters a storage backend and destroys its instance.
Definition
qgsexternalstorageregistry.cpp:52
QgsExternalStorage
Abstract interface for external storage - to be implemented by various backends and registered in Qgs...
Definition
qgsexternalstorage.h:37
qgis_sip.h
SIP_TRANSFER
#define SIP_TRANSFER
Definition
qgis_sip.h:35
Generated on
for QGIS API Documentation by
1.17.0