KLdap

ldapwidgetitemreadconfigserverjob.h
1/*
2 * SPDX-FileCopyrightText: 2020-2024 Laurent Montel <montel@kde.org>
3 *
4 * SPDX-License-Identifier: LGPL-2.0-or-later
5 */
6
7#pragma once
8
9#include <KConfigGroup>
10#include <QObject>
11namespace KLDAPCore
12{
13class LdapServer;
14}
15namespace KLDAPWidgets
16{
17class LdapWidgetItem;
18class LdapWidgetItemReadConfigServerJob : public QObject
19{
21public:
22 explicit LdapWidgetItemReadConfigServerJob(QObject *parent = nullptr);
23 ~LdapWidgetItemReadConfigServerJob() override;
24
25 void start();
26
27 [[nodiscard]] LdapWidgetItem *ldapWidgetItem() const;
28 void setLdapWidgetItem(LdapWidgetItem *ldapWidgetItem);
29
30 [[nodiscard]] int currentIndex() const;
31 void setCurrentIndex(int currentIndex);
32
33 [[nodiscard]] bool active() const;
34 void setActive(bool active);
35
36 [[nodiscard]] KConfigGroup config() const;
37 void setConfig(const KConfigGroup &config);
38
39private:
40 void slotConfigLoaded(const KLDAPCore::LdapServer &server);
41 LdapWidgetItem *mLdapWidgetItem = nullptr;
42 KConfigGroup mConfig;
43 int mCurrentIndex = -1;
44 bool mActive = false;
45};
46}
A class that contains LDAP server connection settings.
Definition ldapserver.h:27
Q_OBJECTQ_OBJECT
QObject * parent() const const
T qobject_cast(QObject *object)
This file is part of the KDE documentation.
Documentation copyright © 1996-2024 The KDE developers.
Generated on Tue Mar 26 2024 11:18:34 by doxygen 1.10.0 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.