PulseAudio Qt Bindings

profile.h
1 /*
2  SPDX-FileCopyrightText: 2014-2015 Harald Sitter <[email protected]>
3 
4  SPDX-License-Identifier: LGPL-2.1-only OR LGPL-3.0-only OR LicenseRef-KDE-Accepted-LGPL
5 */
6 
7 #ifndef PROFILE_H
8 #define PROFILE_H
9 
10 #include "pulseaudioqt_export.h"
11 #include "pulseobject.h"
12 #include <QObject>
13 #include <QString>
14 
15 namespace PulseAudioQt
16 {
17 /**
18  * A PulseAudio profile.
19  */
20 class PULSEAUDIOQT_EXPORT Profile : public PulseObject
21 {
22  Q_OBJECT
23  Q_PROPERTY(QString description READ description NOTIFY descriptionChanged)
24  Q_PROPERTY(quint32 priority READ priority NOTIFY priorityChanged)
25  Q_PROPERTY(Availability availability READ availability NOTIFY availabilityChanged)
26 
27 public:
28  enum Availability { Unknown, Available, Unavailable };
29  Q_ENUM(Availability)
30 
31  ~Profile();
32 
33  /**
34  * A human readable description.
35  */
36  QString description() const;
37 
38  /**
39  * This object's priority. A higher number means higher priority.
40  */
41  quint32 priority() const;
42 
43  /**
44  * Whether this object is available.
45  */
46  Availability availability() const;
47 
48 Q_SIGNALS:
49  /**
50  * Emitted when the description changed.
51  */
52  void descriptionChanged();
53 
54  /**
55  * Emitted when the priority changed.
56  */
57  void priorityChanged();
58 
59  /**
60  * Emitted when the availability changed.
61  */
62  void availabilityChanged();
63 
64 protected:
65  /** @private */
66  explicit Profile(QObject *parent);
67  /** @private */
68  class ProfilePrivate *const d;
69 
70  friend class Device;
71  friend class CardPrivate;
72  friend class PortPrivate;
73 };
74 
75 } // PulseAudioQt
76 
77 #endif // PROFILE_H
A PulseAudio device.
Definition: device.h:23
A PulseAudio profile.
Definition: profile.h:20
Base class for most PulseAudio objects.
Definition: pulseobject.h:24
The primary namespace of PulseAudioQt.
Definition: card.cpp:17
This file is part of the KDE documentation.
Documentation copyright © 1996-2021 The KDE developers.
Generated on Sat Jun 19 2021 23:06:32 by doxygen 1.8.11 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.