Home Assistant Unofficial Reference 2024.12.1
homeassistant.components.heos.media_player Namespace Reference

Classes

class  HeosMediaPlayer
 

Functions

Callable[[_FuncType[_P]], _ReturnFuncType[_P]] _P (str command)
 
None async_setup_entry (HomeAssistant hass, ConfigEntry entry, AddEntitiesCallback async_add_entities)
 

Variables

 _LOGGER = logging.getLogger(__name__)
 
tuple BASE_SUPPORTED_FEATURES
 
dictionary CONTROL_TO_SUPPORT
 
dictionary HA_HEOS_ENQUEUE_MAP
 
dictionary PLAY_STATE_TO_STATE
 

Detailed Description

Denon HEOS Media Player.

Function Documentation

◆ _P()

Callable[[_FuncType[_P]], _ReturnFuncType[_P]] homeassistant.components.heos.media_player._P ( str  command)
private
Return decorator that logs command failure.

Definition at line 95 of file media_player.py.

◆ async_setup_entry()

None homeassistant.components.heos.media_player.async_setup_entry ( HomeAssistant  hass,
ConfigEntry  entry,
AddEntitiesCallback   async_add_entities 
)
Add media players for a config entry.

Definition at line 82 of file media_player.py.

Variable Documentation

◆ _LOGGER

homeassistant.components.heos.media_player._LOGGER = logging.getLogger(__name__)
private

Definition at line 79 of file media_player.py.

◆ BASE_SUPPORTED_FEATURES

tuple homeassistant.components.heos.media_player.BASE_SUPPORTED_FEATURES
Initial value:
1 = (
2  MediaPlayerEntityFeature.VOLUME_MUTE
3  | MediaPlayerEntityFeature.VOLUME_SET
4  | MediaPlayerEntityFeature.VOLUME_STEP
5  | MediaPlayerEntityFeature.CLEAR_PLAYLIST
6  | MediaPlayerEntityFeature.SHUFFLE_SET
7  | MediaPlayerEntityFeature.SELECT_SOURCE
8  | MediaPlayerEntityFeature.PLAY_MEDIA
9  | MediaPlayerEntityFeature.GROUPING
10  | MediaPlayerEntityFeature.BROWSE_MEDIA
11  | MediaPlayerEntityFeature.MEDIA_ENQUEUE
12 )

Definition at line 44 of file media_player.py.

◆ CONTROL_TO_SUPPORT

dictionary homeassistant.components.heos.media_player.CONTROL_TO_SUPPORT
Initial value:
1 = {
2  heos_const.CONTROL_PLAY: MediaPlayerEntityFeature.PLAY,
3  heos_const.CONTROL_PAUSE: MediaPlayerEntityFeature.PAUSE,
4  heos_const.CONTROL_STOP: MediaPlayerEntityFeature.STOP,
5  heos_const.CONTROL_PLAY_PREVIOUS: MediaPlayerEntityFeature.PREVIOUS_TRACK,
6  heos_const.CONTROL_PLAY_NEXT: MediaPlayerEntityFeature.NEXT_TRACK,
7 }

Definition at line 63 of file media_player.py.

◆ HA_HEOS_ENQUEUE_MAP

dictionary homeassistant.components.heos.media_player.HA_HEOS_ENQUEUE_MAP
Initial value:
1 = {
2  None: heos_const.ADD_QUEUE_REPLACE_AND_PLAY,
3  MediaPlayerEnqueue.ADD: heos_const.ADD_QUEUE_ADD_TO_END,
4  MediaPlayerEnqueue.REPLACE: heos_const.ADD_QUEUE_REPLACE_AND_PLAY,
5  MediaPlayerEnqueue.NEXT: heos_const.ADD_QUEUE_PLAY_NEXT,
6  MediaPlayerEnqueue.PLAY: heos_const.ADD_QUEUE_PLAY_NOW,
7 }

Definition at line 71 of file media_player.py.

◆ PLAY_STATE_TO_STATE

dictionary homeassistant.components.heos.media_player.PLAY_STATE_TO_STATE
Initial value:
1 = {
2  heos_const.PLAY_STATE_PLAY: MediaPlayerState.PLAYING,
3  heos_const.PLAY_STATE_STOP: MediaPlayerState.IDLE,
4  heos_const.PLAY_STATE_PAUSE: MediaPlayerState.PAUSED,
5 }

Definition at line 57 of file media_player.py.