KLdap

ldapsearchclientreadconfigserverjob.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 "kldap_core_export.h"
10#include <KConfigGroup>
11#include <QObject>
12namespace KLDAPCore
13{
14class LdapServer;
15class LdapClient;
16class KLDAP_CORE_EXPORT LdapSearchClientReadConfigServerJob : public QObject
17{
18 Q_OBJECT
19public:
20 explicit LdapSearchClientReadConfigServerJob(QObject *parent = nullptr);
21 ~LdapSearchClientReadConfigServerJob() override;
22
23 void start();
24 [[nodiscard]] bool canStart() const;
25
26 [[nodiscard]] int currentIndex() const;
27 void setCurrentIndex(int currentIndex);
28
29 [[nodiscard]] bool active() const;
30 void setActive(bool active);
31
32 [[nodiscard]] KConfigGroup config() const;
33 void setConfig(const KConfigGroup &config);
34
35 [[nodiscard]] LdapClient *ldapClient() const;
36 void setLdapClient(LdapClient *ldapClient);
37
38private:
39 KLDAP_CORE_NO_EXPORT void slotConfigLoaded(const KLDAPCore::LdapServer &server);
40 LdapClient *mLdapClient = nullptr;
41 KConfigGroup mConfig;
42 int mCurrentIndex = -1;
43 bool mActive = false;
44};
45}
A class that contains LDAP server connection settings.
Definition ldapserver.h:27
Q_SCRIPTABLE Q_NOREPLY void start()
This file is part of the KDE documentation.
Documentation copyright © 1996-2024 The KDE developers.
Generated on Fri Oct 11 2024 12:14:23 by doxygen 1.12.0 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.