Akonadi Contacts

openemailaddressjob.h
1/*
2 SPDX-FileCopyrightText: 2010 Tobias Koenig <tokoe@kde.org>
3
4 SPDX-License-Identifier: LGPL-2.0-or-later
5*/
6
7#pragma once
8
9#include "akonadi-contact-widgets_export.h"
10
11#include <KJob>
12
13#include <memory>
14
15namespace Akonadi
16{
17class OpenEmailAddressJobPrivate;
18
19/**
20 * @short A job to open the contact editor for a contact with a given email address.
21 *
22 * The job will check whether a contact with the given email address already
23 * exists in Akonadi. If not, it will add a new contact with the email address
24 * to Akonadi and then opens the contact editor.
25 */
26class AKONADI_CONTACT_WIDGETS_EXPORT OpenEmailAddressJob : public KJob
27{
28 Q_OBJECT
29
30public:
31 /**
32 * Creates a new open email address job.
33 *
34 * @param email The email address to open.
35 * @param parentWidget The widget that will be used as parent for dialog.
36 * @param parent The parent object.
37 */
38 explicit OpenEmailAddressJob(const QString &email, QWidget *parentWidget, QObject *parent = nullptr);
39
40 /**
41 * Destroys the open email address job.
42 */
44
45 /**
46 * Starts the job.
47 */
48 void start() override;
49
50private:
51 //@cond PRIVATE
52 friend class OpenEmailAddressJobPrivate;
53 std::unique_ptr<OpenEmailAddressJobPrivate> const d;
54 //@endcond
55};
56}
A job to open the contact editor for a contact with a given email address.
~OpenEmailAddressJob() override
Destroys the open email address job.
Q_SCRIPTABLE Q_NOREPLY void start()
A widget for editing the display name of a contact.
This file is part of the KDE documentation.
Documentation copyright © 1996-2024 The KDE developers.
Generated on Mon Nov 4 2024 16:36:45 by doxygen 1.12.0 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.