accounts-qt  1.16
Application Class Reference

Information on the client applications of libaccounts. More...

#include <Accounts/Application>

Public Member Functions

 Application ()
 Construct an invalid application.
 
 Application (const Application &other)
 Copy constructor. More...
 
Applicationoperator= (const Application &other)
 
 ~Application ()
 Destructor.
 
bool isValid () const
 Check whether this object represents an Application. More...
 
QString name () const
 Get the unique ID of the application. More...
 
QString displayName () const
 Get the display name of the application. More...
 
QString description () const
 Get the description of the application. More...
 
QString iconName () const
 Get the icon name of the application. More...
 
QString desktopFilePath () const
 Get the .desktop file associated with this application. More...
 
QString trCatalog () const
 Get the translation catalog for the texts returned by the methods of this class. More...
 
bool supportsService (const Service &service) const
 Check whether the application supports the given service. More...
 
QString serviceUsage (const Service &service) const
 Get the description from the application XML file, for the specified service; if not found, get the service-type description instead. More...
 

Detailed Description

Information on the client applications of libaccounts.

The Application structure holds information on the client applications registered with libaccounts. It is instantiated by Manager::application() and Manager::applicationList().

Definition at line 41 of file application.h.

Constructor & Destructor Documentation

◆ Application()

Application ( const Application other)

Copy constructor.

Copying an Application object is very cheap, because the data is shared among copies.

Definition at line 62 of file application.cpp.

Member Function Documentation

◆ description()

QString description ( ) const

Get the description of the application.

Returns
The application description.

Definition at line 131 of file application.cpp.

◆ desktopFilePath()

QString desktopFilePath ( ) const

Get the .desktop file associated with this application.

Returns
The full path to the .desktop file.

Definition at line 160 of file application.cpp.

◆ displayName()

QString displayName ( ) const

Get the display name of the application.

Returns
The application display name.

Definition at line 115 of file application.cpp.

References Application::name().

◆ iconName()

QString iconName ( ) const

Get the icon name of the application.

Returns
The application icon name.

Definition at line 140 of file application.cpp.

◆ isValid()

bool isValid ( ) const

Check whether this object represents an Application.

Returns
true if the Application is a valid one.

Definition at line 95 of file application.cpp.

Referenced by Application::name().

◆ name()

QString name ( ) const

Get the unique ID of the application.

This is the name of the .application file minus the .application suffix.

Returns
The application unique ID.

Definition at line 105 of file application.cpp.

References Application::isValid().

Referenced by Application::displayName().

◆ serviceUsage()

QString serviceUsage ( const Service service) const

Get the description from the application XML file, for the specified service; if not found, get the service-type description instead.

Returns
Usage description of the service.

Definition at line 198 of file application.cpp.

◆ supportsService()

bool supportsService ( const Service service) const

Check whether the application supports the given service.

Parameters
serviceInstance of a Service.
Returns
whether the service is supported by this application.

Definition at line 187 of file application.cpp.

◆ trCatalog()

QString trCatalog ( ) const

Get the translation catalog for the texts returned by the methods of this class.

Returns
The translation catalog name.

Definition at line 177 of file application.cpp.


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