Messagelib

backoffmodemanager.h
1 /*
2  SPDX-FileCopyrightText: 2016-2023 Laurent Montel <[email protected]>
3 
4  SPDX-License-Identifier: LGPL-2.0-or-later
5 */
6 
7 #pragma once
8 
9 #include "webengineviewer_export.h"
10 #include <QObject>
11 #include <memory>
12 namespace WebEngineViewer
13 {
14 class BackOffModeManagerPrivate;
15 // https://developers.google.com/safe-browsing/v4/request-frequency
16 /**
17  * @brief The BackOffModeManager class
18  * @author Laurent Montel <[email protected]>
19  */
20 class WEBENGINEVIEWER_EXPORT BackOffModeManager : public QObject
21 {
22 public:
23  explicit BackOffModeManager(QObject *parent = nullptr);
24  ~BackOffModeManager() override;
25 
26  static BackOffModeManager *self();
27  Q_REQUIRED_RESULT bool isInBackOffMode() const;
28 
29  void startOffMode();
30 
31  Q_REQUIRED_RESULT int numberOfHttpFailed() const;
32 
33 public Q_SLOTS:
34  void slotTimerFinished();
35 
36 private:
37  std::unique_ptr<BackOffModeManagerPrivate> const d;
38 };
39 }
The BackOffModeManager class.
This file is part of the KDE documentation.
Documentation copyright © 1996-2023 The KDE developers.
Generated on Sun Mar 26 2023 04:08:10 by doxygen 1.8.17 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.