python-linkplay 0.1.1__tar.gz → 0.1.2__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (23) hide show
  1. {python_linkplay-0.1.1/src/python_linkplay.egg-info → python_linkplay-0.1.2}/PKG-INFO +1 -1
  2. python_linkplay-0.1.2/src/linkplay/__version__.py +1 -0
  3. {python_linkplay-0.1.1 → python_linkplay-0.1.2}/src/linkplay/controller.py +17 -0
  4. {python_linkplay-0.1.1 → python_linkplay-0.1.2/src/python_linkplay.egg-info}/PKG-INFO +1 -1
  5. python_linkplay-0.1.1/src/linkplay/__version__.py +0 -1
  6. {python_linkplay-0.1.1 → python_linkplay-0.1.2}/LICENSE +0 -0
  7. {python_linkplay-0.1.1 → python_linkplay-0.1.2}/README.md +0 -0
  8. {python_linkplay-0.1.1 → python_linkplay-0.1.2}/pyproject.toml +0 -0
  9. {python_linkplay-0.1.1 → python_linkplay-0.1.2}/setup.cfg +0 -0
  10. {python_linkplay-0.1.1 → python_linkplay-0.1.2}/setup.py +0 -0
  11. {python_linkplay-0.1.1 → python_linkplay-0.1.2}/src/linkplay/__init__.py +0 -0
  12. {python_linkplay-0.1.1 → python_linkplay-0.1.2}/src/linkplay/__main__.py +0 -0
  13. {python_linkplay-0.1.1 → python_linkplay-0.1.2}/src/linkplay/bridge.py +0 -0
  14. {python_linkplay-0.1.1 → python_linkplay-0.1.2}/src/linkplay/consts.py +0 -0
  15. {python_linkplay-0.1.1 → python_linkplay-0.1.2}/src/linkplay/discovery.py +0 -0
  16. {python_linkplay-0.1.1 → python_linkplay-0.1.2}/src/linkplay/endpoint.py +0 -0
  17. {python_linkplay-0.1.1 → python_linkplay-0.1.2}/src/linkplay/exceptions.py +0 -0
  18. {python_linkplay-0.1.1 → python_linkplay-0.1.2}/src/linkplay/utils.py +0 -0
  19. {python_linkplay-0.1.1 → python_linkplay-0.1.2}/src/python_linkplay.egg-info/SOURCES.txt +0 -0
  20. {python_linkplay-0.1.1 → python_linkplay-0.1.2}/src/python_linkplay.egg-info/dependency_links.txt +0 -0
  21. {python_linkplay-0.1.1 → python_linkplay-0.1.2}/src/python_linkplay.egg-info/not-zip-safe +0 -0
  22. {python_linkplay-0.1.1 → python_linkplay-0.1.2}/src/python_linkplay.egg-info/requires.txt +0 -0
  23. {python_linkplay-0.1.1 → python_linkplay-0.1.2}/src/python_linkplay.egg-info/top_level.txt +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: python_linkplay
3
- Version: 0.1.1
3
+ Version: 0.1.2
4
4
  Summary: A Python Library for Seamless LinkPlay Device Control
5
5
  Author: Velleman Group nv
6
6
  License: MIT
@@ -0,0 +1 @@
1
+ __version__ = '0.1.2'
@@ -31,6 +31,15 @@ class LinkPlayController:
31
31
  ]
32
32
  self.bridges.extend(new_bridges)
33
33
 
34
+ async def find_bridge(self, bridge_uuid: str) -> LinkPlayBridge | None:
35
+ """Find a LinkPlay device by its bridge uuid."""
36
+
37
+ for bridge in self.bridges:
38
+ if bridge.device.uuid == bridge_uuid:
39
+ return bridge
40
+
41
+ return None
42
+
34
43
  async def add_bridge(self, bridge_to_add: LinkPlayBridge) -> None:
35
44
  """Add given LinkPlay device if not already added."""
36
45
 
@@ -39,6 +48,14 @@ class LinkPlayController:
39
48
  if bridge_to_add.device.uuid not in current_bridges:
40
49
  self.bridges.append(bridge_to_add)
41
50
 
51
+ async def remove_bridge(self, bridge_to_remove: LinkPlayBridge) -> None:
52
+ """Remove given LinkPlay device if not already deleted."""
53
+
54
+ # Remove bridge
55
+ current_bridges = [bridge.device.uuid for bridge in self.bridges]
56
+ if bridge_to_remove.device.uuid in current_bridges:
57
+ self.bridges.remove(bridge_to_remove)
58
+
42
59
  async def discover_multirooms(self) -> None:
43
60
  """Attempts to discover multirooms on the local network."""
44
61
 
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: python_linkplay
3
- Version: 0.1.1
3
+ Version: 0.1.2
4
4
  Summary: A Python Library for Seamless LinkPlay Device Control
5
5
  Author: Velleman Group nv
6
6
  License: MIT
@@ -1 +0,0 @@
1
- __version__ = '0.1.1'
File without changes