/** * @param CM_Model_Stream_Abstract $stream * @throws CM_Exception_Invalid * @throws CM_Janus_StopStreamError */ protected function _stopStream(CM_Model_Stream_Abstract $stream) { /** @var $streamChannel CM_Model_StreamChannel_Media */ $streamChannel = $stream->getStreamChannel(); $server = $this->_serverList->getById($streamChannel->getServerId()); $result = $this->_httpApiClient->stopStream($server, $stream->getKey()); if (array_key_exists('error', $result)) { throw new CM_Janus_StopStreamError($result['error']); } }
/** * @param CM_Model_Stream_Abstract $stream */ protected function _stopStream(CM_Model_Stream_Abstract $stream) { /** @var $streamChannel CM_Model_StreamChannel_Video */ $streamChannel = $stream->getStreamChannel(); $this->_stopClient($stream->getKey(), $streamChannel->getPrivateHost()); }