Module: Muzak::Player

Defined in:
lib/muzak/player.rb,
lib/muzak/player/mpv.rb,
lib/muzak/player/stub_player.rb

Overview

The namespace for muzak players.

Defined Under Namespace

Classes: MPV, StubPlayer

Constant Summary collapse

PLAYER_MAP =

An association of shorthand player "names" to Class objects.

{
  "stub" => Player::StubPlayer,
  "mpv" => Player::MPV
}.freeze

Class Method Summary collapse

Class Method Details

.load_player!(instance) ⇒ StubPlayer

Returns an instantiated player as specified in Config.player.

Returns:



17
18
19
# File 'lib/muzak/player.rb', line 17

def self.load_player!(instance)
  PLAYER_MAP[Config.player].new(instance)
end