3 namespace Domain\VOs\StepMania
;
5 use Domain\Exception\InvalidDanceModeException
;
7 class DanceMode
implements IDanceMode
9 protected $stepManiaName;
10 protected $prettyName;
12 private $_nameMap = array(
13 'dance-single' => 'Single',
14 'dance-double' => 'Double'
17 public function __construct($stepManiaName)
19 if(array_key_exists($stepManiaName, $this->_nameMap
)) {
20 $this->stepManiaName
= $stepManiaName;
21 $this->prettyName
= $this->_nameMap
[$stepManiaName];
23 throw new InvalidDanceModeException(sprintf('Invalid dance mode %s', $stepManiaName));
27 public function getStepManiaName() {
28 return $this->stepManiaName
;
31 public function getPrettyName() {
32 return $this->prettyName
;