2018-07-19 10:39:30 +02:00
|
|
|
/*
|
|
|
|
|
* Copyright 2018 The WebRTC project authors. All Rights Reserved.
|
|
|
|
|
*
|
|
|
|
|
* Use of this source code is governed by a BSD-style license
|
|
|
|
|
* that can be found in the LICENSE file in the root of the source
|
|
|
|
|
* tree. An additional intellectual property rights grant can be found
|
|
|
|
|
* in the file PATENTS. All contributing project authors may
|
|
|
|
|
* be found in the AUTHORS file in the root of the source tree.
|
|
|
|
|
*/
|
|
|
|
|
|
2019-01-11 09:11:00 -08:00
|
|
|
#include "api/rtp_transceiver_interface.h"
|
2018-07-19 10:39:30 +02:00
|
|
|
|
2024-09-12 10:53:32 +02:00
|
|
|
#include <optional>
|
|
|
|
|
|
2024-09-04 14:55:22 +03:00
|
|
|
#include "api/rtc_error.h"
|
|
|
|
|
#include "api/rtp_transceiver_direction.h"
|
2018-10-23 12:03:01 +02:00
|
|
|
#include "rtc_base/checks.h"
|
|
|
|
|
|
2018-07-19 10:39:30 +02:00
|
|
|
namespace webrtc {
|
|
|
|
|
|
|
|
|
|
RtpTransceiverInit::RtpTransceiverInit() = default;
|
|
|
|
|
|
2018-07-20 11:09:32 +02:00
|
|
|
RtpTransceiverInit::RtpTransceiverInit(const RtpTransceiverInit& rhs) = default;
|
|
|
|
|
|
2018-07-19 10:39:30 +02:00
|
|
|
RtpTransceiverInit::~RtpTransceiverInit() = default;
|
|
|
|
|
|
2024-08-29 13:00:40 +00:00
|
|
|
std::optional<RtpTransceiverDirection>
|
2018-07-19 10:39:30 +02:00
|
|
|
RtpTransceiverInterface::fired_direction() const {
|
2024-08-29 13:00:40 +00:00
|
|
|
return std::nullopt;
|
2018-07-19 10:39:30 +02:00
|
|
|
}
|
|
|
|
|
|
2020-08-11 09:54:02 +02:00
|
|
|
bool RtpTransceiverInterface::stopping() const {
|
|
|
|
|
return false;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
void RtpTransceiverInterface::Stop() {
|
|
|
|
|
StopInternal();
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
RTCError RtpTransceiverInterface::StopStandard() {
|
2021-11-15 16:57:07 +01:00
|
|
|
RTC_DCHECK_NOTREACHED()
|
|
|
|
|
<< "DEBUG: RtpTransceiverInterface::StopStandard called";
|
2020-08-11 09:54:02 +02:00
|
|
|
return RTCError::OK();
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
void RtpTransceiverInterface::StopInternal() {
|
2021-11-15 16:57:07 +01:00
|
|
|
RTC_DCHECK_NOTREACHED()
|
|
|
|
|
<< "DEBUG: RtpTransceiverInterface::StopInternal called";
|
2020-08-11 09:54:02 +02:00
|
|
|
}
|
|
|
|
|
|
|
|
|
|
// TODO(bugs.webrtc.org/11839) Remove default implementations when clients
|
|
|
|
|
// are updated.
|
|
|
|
|
void RtpTransceiverInterface::SetDirection(
|
|
|
|
|
RtpTransceiverDirection new_direction) {
|
|
|
|
|
SetDirectionWithError(new_direction);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
RTCError RtpTransceiverInterface::SetDirectionWithError(
|
|
|
|
|
RtpTransceiverDirection new_direction) {
|
2021-11-15 16:57:07 +01:00
|
|
|
RTC_DCHECK_NOTREACHED() << "Default implementation called";
|
2020-08-11 09:54:02 +02:00
|
|
|
return RTCError::OK();
|
|
|
|
|
}
|
|
|
|
|
|
2018-07-19 10:39:30 +02:00
|
|
|
} // namespace webrtc
|