mirror of
https://github.com/home-assistant/developers.home-assistant.git
synced 2025-07-09 18:36:29 +00:00
Update ssdp callback matching to support MATCH_ALL (#956)
This commit is contained in:
parent
efe7943736
commit
371b5b5ca5
@ -119,6 +119,22 @@ entry.async_on_unload(
|
||||
)
|
||||
```
|
||||
|
||||
The below example shows registering to get callbacks when the `x-rincon-bootseq` header is present.
|
||||
|
||||
```
|
||||
from homeassistant.components import ssdp
|
||||
from homeassistant.const import MATCH_ALL
|
||||
|
||||
...
|
||||
|
||||
entry.async_on_unload(
|
||||
ssdp.async_register_callback(
|
||||
hass, _async_discovered_player, {"x-rincon-bootseq": MATCH_ALL}
|
||||
)
|
||||
)
|
||||
```
|
||||
|
||||
|
||||
## Network
|
||||
|
||||
For integrations that use a discovery method that is not built-in and need to access the user's network adapter configuration, the following helper API should be used.
|
||||
|
Loading…
x
Reference in New Issue
Block a user