QGIS API Documentation 3.41.0-Master (fda2aa46e9a)
Loading...
Searching...
No Matches
Public Types | Public Member Functions | Static Public Member Functions | List of all members
QgsAuthMethodRegistry Class Reference

A registry / canonical manager of authentication methods. More...

#include <qgsauthmethodregistry.h>

Public Types

typedef std::map< QString, QgsAuthMethodMetadata * > AuthMethods
 Type for auth method metadata associative container.
 

Public Member Functions

virtual ~QgsAuthMethodRegistry ()
 
QStringList authMethodList () const
 Returns list of available auth methods by their keys.
 
const QgsAuthMethodMetadataauthMethodMetadata (const QString &authMethodKey) const
 Returns metadata of the auth method or nullptr if not found.
 
QgsAuthMethodcreateAuthMethod (const QString &authMethodKey)
 Create an instance of the auth method.
 
QWidget * editWidget (const QString &authMethodKey, QWidget *parent=nullptr)
 Returns the GUI edit widget associated with the auth method.
 
Q_DECL_DEPRECATED QString library (const QString &authMethodKey) const
 Returns path for the library of the auth method.
 
QDir libraryDirectory () const
 Returns library directory where plugins are found.
 
QString pluginList (bool asHtml=false) const
 Returns list of auth method plugins found.
 
void setLibraryDirectory (const QDir &path)
 Sets library directory where to search for plugins.
 

Static Public Member Functions

static QgsAuthMethodRegistryinstance (const QString &pluginPath=QString())
 Means of accessing canonical single instance.
 

Detailed Description

A registry / canonical manager of authentication methods.

This is a Singleton class that manages authentication method plugin access.

Loaded auth methods may be restricted using QGIS_AUTHMETHOD_FILE environment variable. QGIS_AUTHMETHOD_FILE is regexp pattern applied to auth method file name (not auth method key). For example, if the variable is set to basic|pkipaths it will load only auth methods basic, and pkipaths.

Note
not available in Python bindings

Definition at line 47 of file qgsauthmethodregistry.h.

Member Typedef Documentation

◆ AuthMethods

Type for auth method metadata associative container.

Definition at line 101 of file qgsauthmethodregistry.h.

Constructor & Destructor Documentation

◆ ~QgsAuthMethodRegistry()

QgsAuthMethodRegistry::~QgsAuthMethodRegistry ( )
virtual

Definition at line 194 of file qgsauthmethodregistry.cpp.

Member Function Documentation

◆ authMethodList()

QStringList QgsAuthMethodRegistry::authMethodList ( ) const

Returns list of available auth methods by their keys.

Definition at line 315 of file qgsauthmethodregistry.cpp.

◆ authMethodMetadata()

const QgsAuthMethodMetadata * QgsAuthMethodRegistry::authMethodMetadata ( const QString &  authMethodKey) const

Returns metadata of the auth method or nullptr if not found.

Definition at line 298 of file qgsauthmethodregistry.cpp.

◆ createAuthMethod()

QgsAuthMethod * QgsAuthMethodRegistry::createAuthMethod ( const QString &  authMethodKey)

Create an instance of the auth method.

Parameters
authMethodKeyidentificator of the auth method
Returns
instance of auth method or nullptr on error

Definition at line 303 of file qgsauthmethodregistry.cpp.

◆ editWidget()

QWidget * QgsAuthMethodRegistry::editWidget ( const QString &  authMethodKey,
QWidget *  parent = nullptr 
)

Returns the GUI edit widget associated with the auth method.

Parameters
parentParent widget
authMethodKeyidentificator of the auth method

◆ instance()

QgsAuthMethodRegistry * QgsAuthMethodRegistry::instance ( const QString &  pluginPath = QString())
static

Means of accessing canonical single instance.

Definition at line 47 of file qgsauthmethodregistry.cpp.

◆ library()

QString QgsAuthMethodRegistry::library ( const QString &  authMethodKey) const

Returns path for the library of the auth method.

Deprecated:
QGIS 3.22. Methods may not need to be loaded from a library (empty string returned).

Definition at line 225 of file qgsauthmethodregistry.cpp.

◆ libraryDirectory()

QDir QgsAuthMethodRegistry::libraryDirectory ( ) const

Returns library directory where plugins are found.

Definition at line 284 of file qgsauthmethodregistry.cpp.

◆ pluginList()

QString QgsAuthMethodRegistry::pluginList ( bool  asHtml = false) const

Returns list of auth method plugins found.

Definition at line 239 of file qgsauthmethodregistry.cpp.

◆ setLibraryDirectory()

void QgsAuthMethodRegistry::setLibraryDirectory ( const QDir &  path)

Sets library directory where to search for plugins.

Definition at line 289 of file qgsauthmethodregistry.cpp.


The documentation for this class was generated from the following files: