blob: d203a5275fd3b0608b19583b3070ebcecdccb9ed (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
|
<?php
class StreamList extends ModelBase implements IteratorAggregate
{
private $streams = array();
public function __construct($slug)
{
if(! $this->has('ROOMS.'.$slug))
throw new NotFoundException('Room '.$slug);
$this->slug = $slug;
$this->streams = array();
$streams = $this->get("ROOMS.$slug.STREAMS");
foreach((array)$streams as $stream) {
$this->streams[$stream] = explode('-', $stream);
}
}
public function getRoomSlug() {
return $this->slug;
}
public function getRoom() {
return new Room($this->getRoomSlug());
}
public function getStreams() {
return array_keys($this->streams);
}
public function getIterator() {
return new ArrayIterator($this->streams);
}
public function hasTranslation() {
}
public function hasRTMP() {
}
public function hasHLS() {
}
public function hasWebM() {
}
public function hasHD() {
}
public function hasSD() {
}
}
|