1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
//! Device hotplug vocabulary ([`DeviceEvent`], [`DeviceHotplug`]).
//!
//! **Vocabulary only in this pass — no backend implements [`DeviceHotplug`]
//! yet.** See [ADR-0005](../adr/0005-device-selection.md) § Hotplug: v1
//! scope is Microphone/Loopback only, via `IMMNotificationClient`, and is a
//! separate follow-up task from the one that added these types. Camera and
//! Screen hotplug are deferred further still (different OS mechanism —
//! `WM_DEVICECHANGE`/`WM_DISPLAYCHANGE`, message-pump-based).
use crateDeviceKind;
use crateDeviceId;
use crateCaptureError;
/// A device-change notification.
/// Sync-poll device-change notifications.
///
/// Mirrors [`crate::AudioCapture::poll_frame`]'s idle convention (`Ok(None)`
/// = nothing pending) per `docs/spec/async-and-streaming.md`'s sync/poll
/// policy for platform sessions.
///
/// A concrete backend type (e.g. a future `WindowsDeviceHotplug::open(kinds:
/// &[DeviceKind]) -> Result<Self, CaptureError>`, `Type::open` shape per
/// `docs/conventions/code-style.md` § Public Rust API shape) is expected to
/// own the real OS registration and unregister it on
/// [`close`](Self::close)/`Drop` — a genuine RAII resource, since a
/// registered OS callback that is never unregistered is a real
/// leak/dangling-callback risk. **No such backend type exists yet** — see the
/// module docs.