BluezQt

input.h
1 /*
2  * BluezQt - Asynchronous BlueZ wrapper library
3  *
4  * SPDX-FileCopyrightText: 2015 David Rosca <[email protected]>
5  *
6  * SPDX-License-Identifier: LGPL-2.1-only OR LGPL-3.0-only OR LicenseRef-KDE-Accepted-LGPL
7  */
8 
9 #ifndef BLUEZQT_INPUT_H
10 #define BLUEZQT_INPUT_H
11 
12 #include <QObject>
13 
14 #include "bluezqt_export.h"
15 #include "types.h"
16 
17 namespace BluezQt
18 {
19 /**
20  * @class BluezQt::Input input.h <BluezQt/Input>
21  *
22  * %Device input.
23  *
24  * This class represents an input interface.
25  */
26 class BLUEZQT_EXPORT Input : public QObject
27 {
28  Q_OBJECT
29  Q_PROPERTY(ReconnectMode reconnectMode READ reconnectMode NOTIFY reconnectModeChanged)
30 
31 public:
32  /** Reconnect mode. */
34  /** Device and host are not required to automatically restore the connection. */
36  /** Host restores the connection. */
38  /** Device restores the connection. */
40  /** Device shall attempt to restore the lost connection, but host may also restore the connection. */
42  };
43  Q_ENUM(ReconnectMode)
44 
45  /**
46  * Destroys an Input object.
47  */
48  ~Input() override;
49 
50  /**
51  * Returns a shared pointer from this.
52  *
53  * @return InputPtr
54  */
55  InputPtr toSharedPtr() const;
56 
57  /**
58  * Returns the reconnect mode.
59  *
60  * @return reconnect mode
61  */
62  ReconnectMode reconnectMode() const;
63 
64 Q_SIGNALS:
65  /**
66  * Indicates that input's reconnect mode have changed.
67  */
68  void reconnectModeChanged(ReconnectMode mode);
69 
70 private:
71  BLUEZQT_NO_EXPORT explicit Input(const QString &path, const QVariantMap &properties);
72 
73  class InputPrivate *const d;
74 
75  friend class InputPrivate;
76  friend class DevicePrivate;
77 };
78 
79 } // namespace BluezQt
80 
81 #endif // BLUEZQT_INPUT_H
ReconnectMode
Reconnect mode.
Definition: input.h:33
@ AnyReconnect
Device shall attempt to restore the lost connection, but host may also restore the connection.
Definition: input.h:41
@ NoReconnect
Device and host are not required to automatically restore the connection.
Definition: input.h:35
@ HostReconnect
Host restores the connection.
Definition: input.h:37
@ DeviceReconnect
Device restores the connection.
Definition: input.h:39
This file is part of the KDE documentation.
Documentation copyright © 1996-2023 The KDE developers.
Generated on Sat Sep 30 2023 04:05:22 by doxygen 1.8.17 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.