QGIS API Documentation  2.18.3-Las Palmas (77b8c3d)
Static Public Member Functions | List of all members
QgsAuthGuiUtils Class Reference

Utility functions for use by authentication GUI widgets or standalone apps. More...

#include <qgsauthguiutils.h>

Static Public Member Functions

static void clearCachedAuthenticationConfigs (QgsMessageBar *msgbar, int timeout=0)
 Clear all cached authentication configs for session. More...
 
static void clearCachedMasterPassword (QgsMessageBar *msgbar, int timeout=0)
 Clear the currently cached master password (not its hash in database) More...
 
static void eraseAuthenticationDatabase (QgsMessageBar *msgbar, int timeout=0, QWidget *parent=nullptr)
 Completely clear out the authentication database (configs and master password) More...
 
static void fileFound (bool found, QWidget *widget)
 Color a widget via a stylesheet if a file path is found or not. More...
 
static QString getOpenFileName (QWidget *parent, const QString &title, const QString &extfilter)
 Open file dialog for auth associated widgets. More...
 
static QColor greenColor ()
 Green color representing valid, trusted, etc. More...
 
static QString greenTextStyleSheet (const QString &selector="*")
 Green text stylesheet representing valid, trusted, etc. More...
 
static bool isDisabled (QgsMessageBar *msgbar, int timeout=0)
 Verify the authentication system is active, else notify user. More...
 
static QColor orangeColor ()
 Orange color representing loaded component, but not stored in database. More...
 
static QString orangeTextStyleSheet (const QString &selector="*")
 Orange text stylesheet representing loaded component, but not stored in database. More...
 
static QColor redColor ()
 Red color representing invalid, untrusted, etc. More...
 
static QString redTextStyleSheet (const QString &selector="*")
 Red text stylesheet representing invalid, untrusted, etc. More...
 
static void removeAuthenticationConfigs (QgsMessageBar *msgbar, int timeout=0, QWidget *parent=nullptr)
 Remove all authentication configs. More...
 
static void resetMasterPassword (QgsMessageBar *msgbar, int timeout=0, QWidget *parent=nullptr)
 Reset the cached master password, updating its hash in authentication database and reseting all existing configs to use it. More...
 
static void setMasterPassword (QgsMessageBar *msgbar, int timeout=0)
 Sets the cached master password (and verifies it if its hash is in authentication database) More...
 
static QColor yellowColor ()
 Yellow color representing caution regarding action. More...
 

Detailed Description

Utility functions for use by authentication GUI widgets or standalone apps.

Note
not available in Python bindings

Definition at line 30 of file qgsauthguiutils.h.

Member Function Documentation

void QgsAuthGuiUtils::clearCachedAuthenticationConfigs ( QgsMessageBar msgbar,
int  timeout = 0 
)
static

Clear all cached authentication configs for session.

Definition at line 158 of file qgsauthguiutils.cpp.

void QgsAuthGuiUtils::clearCachedMasterPassword ( QgsMessageBar msgbar,
int  timeout = 0 
)
static

Clear the currently cached master password (not its hash in database)

Definition at line 92 of file qgsauthguiutils.cpp.

void QgsAuthGuiUtils::eraseAuthenticationDatabase ( QgsMessageBar msgbar,
int  timeout = 0,
QWidget parent = nullptr 
)
static

Completely clear out the authentication database (configs and master password)

Definition at line 195 of file qgsauthguiutils.cpp.

void QgsAuthGuiUtils::fileFound ( bool  found,
QWidget widget 
)
static

Color a widget via a stylesheet if a file path is found or not.

Definition at line 238 of file qgsauthguiutils.cpp.

QString QgsAuthGuiUtils::getOpenFileName ( QWidget parent,
const QString title,
const QString extfilter 
)
static

Open file dialog for auth associated widgets.

Definition at line 252 of file qgsauthguiutils.cpp.

QColor QgsAuthGuiUtils::greenColor ( )
static

Green color representing valid, trusted, etc.

certificate

Definition at line 30 of file qgsauthguiutils.cpp.

QString QgsAuthGuiUtils::greenTextStyleSheet ( const QString selector = "*")
static

Green text stylesheet representing valid, trusted, etc.

certificate

Definition at line 50 of file qgsauthguiutils.cpp.

bool QgsAuthGuiUtils::isDisabled ( QgsMessageBar msgbar,
int  timeout = 0 
)
static

Verify the authentication system is active, else notify user.

Definition at line 65 of file qgsauthguiutils.cpp.

QColor QgsAuthGuiUtils::orangeColor ( )
static

Orange color representing loaded component, but not stored in database.

Definition at line 35 of file qgsauthguiutils.cpp.

QString QgsAuthGuiUtils::orangeTextStyleSheet ( const QString selector = "*")
static

Orange text stylesheet representing loaded component, but not stored in database.

Definition at line 55 of file qgsauthguiutils.cpp.

QColor QgsAuthGuiUtils::redColor ( )
static

Red color representing invalid, untrusted, etc.

certificate

Definition at line 40 of file qgsauthguiutils.cpp.

QString QgsAuthGuiUtils::redTextStyleSheet ( const QString selector = "*")
static

Red text stylesheet representing invalid, untrusted, etc.

certificate

Definition at line 60 of file qgsauthguiutils.cpp.

void QgsAuthGuiUtils::removeAuthenticationConfigs ( QgsMessageBar msgbar,
int  timeout = 0,
QWidget parent = nullptr 
)
static

Remove all authentication configs.

Definition at line 168 of file qgsauthguiutils.cpp.

void QgsAuthGuiUtils::resetMasterPassword ( QgsMessageBar msgbar,
int  timeout = 0,
QWidget parent = nullptr 
)
static

Reset the cached master password, updating its hash in authentication database and reseting all existing configs to use it.

Definition at line 114 of file qgsauthguiutils.cpp.

void QgsAuthGuiUtils::setMasterPassword ( QgsMessageBar msgbar,
int  timeout = 0 
)
static

Sets the cached master password (and verifies it if its hash is in authentication database)

Definition at line 77 of file qgsauthguiutils.cpp.

QColor QgsAuthGuiUtils::yellowColor ( )
static

Yellow color representing caution regarding action.

Definition at line 45 of file qgsauthguiutils.cpp.


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