QGIS API Documentation  3.10.0-A Coruña (6c816b4204)
qgsabstractproviderconnection.cpp
Go to the documentation of this file.
1 /***************************************************************************
2  qgsabstractproviderconnection.cpp - QgsAbstractProviderConnection
3 
4  ---------------------
5  begin : 2.8.2019
6  copyright : (C) 2019 by Alessandro Pasotti
7  email : elpaso at itopen dot it
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  ***************************************************************************/
17 
18 
20 {
21  Q_UNUSED( name );
22  // Note: concrete classes must implement the logic to read the configuration from the settings
23  // and create mUri
24 }
25 
27  : mUri( uri )
28  , mConfiguration( configuration )
29 {
30 
31 }
32 
34 {
35  return mUri;
36 }
37 
39 {
40  mUri = uri;
41 }
42 
44 {
45  return mConfiguration;
46 }
47 
49 {
50  mConfiguration = configuration;
51 }
void setUri(const QString &uri)
Sets the connection data source URI to uri.
QgsAbstractProviderConnection(const QString &name)
Creates a new connection with name by reading its configuration from the settings.
QString uri() const
Returns the connection data source URI string representation.
QVariantMap configuration() const
Returns the connection configuration parameters.
void setConfiguration(const QVariantMap &configuration)
Sets the connection configuration.