aboutsummaryrefslogtreecommitdiff
path: root/model/Room.php
diff options
context:
space:
mode:
authorMaZderMind2015-03-15 19:13:25 +0100
committerMaZderMind2015-03-29 21:42:01 +0200
commitea4b6c7699a7fbb7be3d9e5ce86c84a36b63f569 (patch)
treec919029a8b12e43c363b898a1ff9f7adf5c3312b /model/Room.php
parent97fe6bf0af2989abbaaba138df3c54c4e55af3c9 (diff)
Move get/set-Calls into ModelBase and abstract all access into a Model
Conflicts: model/Overview.php model/Room.php model/StreamList.php tests/ModelTestbase.php
Diffstat (limited to 'model/Room.php')
-rw-r--r--model/Room.php10
1 files changed, 5 insertions, 5 deletions
diff --git a/model/Room.php b/model/Room.php
index fc1b40d..c7e51f9 100644
--- a/model/Room.php
+++ b/model/Room.php
@@ -1,12 +1,12 @@
<?php
-class Room
+class Room extends ModelBase
{
private $slug;
public function __construct($slug)
{
- if(! has('ROOMS.'.$slug))
+ if(! $this->has('ROOMS.'.$slug))
throw new NotFoundException('Room '.$slug);
$this->slug = $slug;
@@ -26,11 +26,11 @@ class Room
}
public function getStream() {
- return get('ROOMS.'.$this->getSlug().'.STREAM', $this->getSlug());
+ return $this->get('ROOMS.'.$this->getSlug().'.STREAM', $this->getSlug());
}
public function getDisplay() {
- return get('ROOMS.'.$this->getSlug().'.DISPLAY', $this->getSlug());
+ return $this->get('ROOMS.'.$this->getSlug().'.DISPLAY', $this->getSlug());
}
@@ -40,6 +40,6 @@ class Room
}
public function hasSchedule() {
- return get('ROOMS.'.$this->getSlug().'.SCHEDULE') && has('SCHEDULE');
+ return $this->get('ROOMS.'.$this->getSlug().'.SCHEDULE') && $this->has('SCHEDULE');
}
}