summaryrefslogtreecommitdiff
path: root/src/lib/alsa
diff options
context:
space:
mode:
authorMax Kellermann <max@musicpd.org>2017-12-19 08:26:06 +0100
committerMax Kellermann <max@musicpd.org>2017-12-19 08:41:53 +0100
commitcd3ed720e0b4221ddc5eef22574764967972b1d1 (patch)
tree05ef5843bc0273aab038e4d670ba8f9055ff783f /src/lib/alsa
parent37c27fa60658c1c997f843e3330e68e614a50ac2 (diff)
lib/alsa/AllowedFormat: add API documentation
Diffstat (limited to 'src/lib/alsa')
-rw-r--r--src/lib/alsa/AllowedFormat.hxx14
1 files changed, 14 insertions, 0 deletions
diff --git a/src/lib/alsa/AllowedFormat.hxx b/src/lib/alsa/AllowedFormat.hxx
index 3182b71b8..12bc5a21f 100644
--- a/src/lib/alsa/AllowedFormat.hxx
+++ b/src/lib/alsa/AllowedFormat.hxx
@@ -29,14 +29,28 @@ struct StringView;
namespace Alsa {
+/**
+ * An audio format for the "allowed_formats" setting of
+ * #AlsaOutputPlugin.
+ */
struct AllowedFormat {
AudioFormat format;
#ifdef ENABLE_DSD
bool dop;
#endif
+ /**
+ * Parse a format string.
+ *
+ * Throws std::runtime_error on error.
+ */
explicit AllowedFormat(StringView s);
+ /**
+ * Parse a list of formats separated by space.
+ *
+ * Throws std::runtime_error on error.
+ */
static std::forward_list<AllowedFormat> ParseList(StringView s);
};