Files
php-pulseaudio/src/Sink/Sink.php

78 lines
1.3 KiB
PHP
Raw Normal View History

2017-02-13 02:53:48 +01:00
<?php
namespace NoccyLabs\PulseAudio\Sink;
2017-02-13 22:50:11 +01:00
use NoccyLabs\PulseAudio\PulseAudio;
2017-02-13 02:53:48 +01:00
use NoccyLabs\PulseAudio\PropertyList;
class Sink
{
protected $index;
protected $name;
protected $card;
protected $driver;
protected $properties;
2017-02-13 22:50:11 +01:00
protected $pulse;
protected $monitor;
public function __construct(PulseAudio $pulse, $index, array $sink)
2017-02-13 02:53:48 +01:00
{
2017-02-13 22:50:11 +01:00
$this->pulse = $pulse;
2017-02-13 02:53:48 +01:00
$this->index = $index;
$this->name = $sink['name'];
2017-02-13 22:50:11 +01:00
//$this->card = $sink['card'];
2017-02-13 02:53:48 +01:00
$this->driver = $sink['driver'];
2017-02-13 22:50:11 +01:00
$this->monitor = $sink['monitor source'];
2017-02-13 02:53:48 +01:00
$this->properties = new PropertyList($sink['properties'], true);
}
public function getProperties()
{
return $this->properties;
}
public function getIndex()
{
return $this->index;
}
public function getName()
{
return $this->name;
}
public function getCard()
{
return $this->card;
}
public function getDriver()
{
return $this->driver;
}
2017-02-13 22:50:11 +01:00
public function getMonitorIndex()
{
return $this->monitor;
}
2017-02-13 02:53:48 +01:00
public function moveToSink(Sink $sink)
{
}
2017-02-13 22:50:11 +01:00
public function createRecorder()
{
return new Recorder($this);
}
2017-02-13 02:53:48 +01:00
}