Akonadi::EmailAddressSelection

Search for usage in LXR

Akonadi::EmailAddressSelection Class Reference

#include <emailaddressselection.h>

Public Types

using List = QVector< EmailAddressSelection >
 

Public Member Functions

 EmailAddressSelection ()
 
 EmailAddressSelection (const EmailAddressSelection &other)
 
 ~EmailAddressSelection ()
 
QString email () const
 
bool isValid () const
 
Akonadi::Item item () const
 
QString name () const
 
EmailAddressSelectionoperator= (const EmailAddressSelection &other)
 
QString quotedEmail () const
 

Detailed Description

An selection of an email address and corresponding name.

This class encapsulates the selection of an email address and name as it is returned by EmailAddressSelectionWidget or EmailAddressSelectionDialog.

It offers convenience methods to retrieve the quoted version of the email address and access to the Akonadi item that is associated with this address.

Author
Tobias Koenig tokoe[email protected]@kde[email protected].org
Since
4.5

Definition at line 36 of file emailaddressselection.h.

Member Typedef Documentation

◆ List

A list of email address selection objects.

Definition at line 42 of file emailaddressselection.h.

Constructor & Destructor Documentation

◆ EmailAddressSelection() [1/2]

EmailAddressSelection::EmailAddressSelection ( )

Creates a new email address selection.

Definition at line 31 of file emailaddressselection.cpp.

◆ EmailAddressSelection() [2/2]

EmailAddressSelection::EmailAddressSelection ( const EmailAddressSelection other)
default

Creates a new email address selection from an other selection.

◆ ~EmailAddressSelection()

EmailAddressSelection::~EmailAddressSelection ( )
default

Destroys the email address selection.

Member Function Documentation

◆ email()

QString EmailAddressSelection::email ( ) const

Returns the address part of the selected email address.

Note
If a contact group has been selected, the name of the contact group is returned here and must be expanded by the caller.

Definition at line 61 of file emailaddressselection.cpp.

◆ isValid()

bool EmailAddressSelection::isValid ( ) const

Returns whether the selection is valid.

Definition at line 51 of file emailaddressselection.cpp.

◆ item()

Akonadi::Item EmailAddressSelection::item ( ) const

Returns the Akonadi item that is associated with the selected email address.

Definition at line 81 of file emailaddressselection.cpp.

◆ name()

QString EmailAddressSelection::name ( ) const

Returns the name that is associated with the selected email address.

Definition at line 56 of file emailaddressselection.cpp.

◆ operator=()

EmailAddressSelection & EmailAddressSelection::operator= ( const EmailAddressSelection other)

Replaces this email address selection with the other selection.

Definition at line 40 of file emailaddressselection.cpp.

◆ quotedEmail()

QString EmailAddressSelection::quotedEmail ( ) const

Returns the name and email address together, properly quoted if needed.

Note
If a contact group has been selected, the name of the contact group is returned here and must be expanded by the caller.

Definition at line 66 of file emailaddressselection.cpp.


The documentation for this class was generated from the following files:
This file is part of the KDE documentation.
Documentation copyright © 1996-2022 The KDE developers.
Generated on Sun Dec 4 2022 03:52:27 by doxygen 1.8.17 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.