mirror of
https://github.com/mollyim/webrtc.git
synced 2025-05-12 21:30:45 +01:00
Remove RTC_DISALLOW_COPY_AND_ASSIGN more.
Bug: webrtc:13555, webrtc:13082 Change-Id: I9c07708108da0a26f5e228384fd56cef4d1540b3 Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/247300 Reviewed-by: Harald Alvestrand <hta@webrtc.org> Reviewed-by: Tomas Gunnarsson <tommi@webrtc.org> Reviewed-by: Artem Titov <titovartem@webrtc.org> Commit-Queue: (Daniel.L) Byoungchan Lee <daniel.l@hpcnt.com> Cr-Commit-Position: refs/heads/main@{#35749}
This commit is contained in:
parent
cf9899c518
commit
c065e739e2
28 changed files with 100 additions and 86 deletions
|
@ -16,7 +16,6 @@
|
|||
|
||||
#include "api/audio/channel_layout.h"
|
||||
#include "api/rtp_packet_infos.h"
|
||||
#include "rtc_base/constructor_magic.h"
|
||||
|
||||
namespace webrtc {
|
||||
|
||||
|
@ -58,6 +57,9 @@ class AudioFrame {
|
|||
|
||||
AudioFrame();
|
||||
|
||||
AudioFrame(const AudioFrame&) = delete;
|
||||
AudioFrame& operator=(const AudioFrame&) = delete;
|
||||
|
||||
// Resets all members to their default state.
|
||||
void Reset();
|
||||
// Same as Reset(), but leaves mute state unchanged. Muting a frame requires
|
||||
|
@ -164,8 +166,6 @@ class AudioFrame {
|
|||
// capture timestamp of a received frame is found in `packet_infos_`.
|
||||
// This timestamp MUST be based on the same clock as rtc::TimeMillis().
|
||||
absl::optional<int64_t> absolute_capture_timestamp_ms_;
|
||||
|
||||
RTC_DISALLOW_COPY_AND_ASSIGN(AudioFrame);
|
||||
};
|
||||
|
||||
} // namespace webrtc
|
||||
|
|
|
@ -20,7 +20,6 @@
|
|||
#include "absl/types/optional.h"
|
||||
#include "api/array_view.h"
|
||||
#include "rtc_base/buffer.h"
|
||||
#include "rtc_base/constructor_magic.h"
|
||||
|
||||
namespace webrtc {
|
||||
|
||||
|
@ -37,6 +36,9 @@ class AudioDecoder {
|
|||
AudioDecoder() = default;
|
||||
virtual ~AudioDecoder() = default;
|
||||
|
||||
AudioDecoder(const AudioDecoder&) = delete;
|
||||
AudioDecoder& operator=(const AudioDecoder&) = delete;
|
||||
|
||||
class EncodedAudioFrame {
|
||||
public:
|
||||
struct DecodeResult {
|
||||
|
@ -187,9 +189,6 @@ class AudioDecoder {
|
|||
int sample_rate_hz,
|
||||
int16_t* decoded,
|
||||
SpeechType* speech_type);
|
||||
|
||||
private:
|
||||
RTC_DISALLOW_COPY_AND_ASSIGN(AudioDecoder);
|
||||
};
|
||||
|
||||
} // namespace webrtc
|
||||
|
|
|
@ -22,7 +22,6 @@
|
|||
|
||||
#include "api/candidate.h"
|
||||
#include "api/jsep.h"
|
||||
#include "rtc_base/constructor_magic.h"
|
||||
#include "rtc_base/system/rtc_export.h"
|
||||
|
||||
namespace webrtc {
|
||||
|
@ -64,6 +63,10 @@ class JsepCandidateCollection : public IceCandidateCollection {
|
|||
// Move constructor is defined so that a vector of JsepCandidateCollections
|
||||
// can be resized.
|
||||
JsepCandidateCollection(JsepCandidateCollection&& o);
|
||||
|
||||
JsepCandidateCollection(const JsepCandidateCollection&) = delete;
|
||||
JsepCandidateCollection& operator=(const JsepCandidateCollection&) = delete;
|
||||
|
||||
// Returns a copy of the candidate collection.
|
||||
JsepCandidateCollection Clone() const;
|
||||
size_t count() const override;
|
||||
|
@ -80,8 +83,6 @@ class JsepCandidateCollection : public IceCandidateCollection {
|
|||
|
||||
private:
|
||||
std::vector<std::unique_ptr<JsepIceCandidate>> candidates_;
|
||||
|
||||
RTC_DISALLOW_COPY_AND_ASSIGN(JsepCandidateCollection);
|
||||
};
|
||||
|
||||
} // namespace webrtc
|
||||
|
|
|
@ -22,7 +22,6 @@
|
|||
#include "api/candidate.h"
|
||||
#include "api/jsep.h"
|
||||
#include "api/jsep_ice_candidate.h"
|
||||
#include "rtc_base/constructor_magic.h"
|
||||
|
||||
namespace cricket {
|
||||
class SessionDescription;
|
||||
|
@ -43,6 +42,9 @@ class JsepSessionDescription : public SessionDescriptionInterface {
|
|||
absl::string_view session_version);
|
||||
virtual ~JsepSessionDescription();
|
||||
|
||||
JsepSessionDescription(const JsepSessionDescription&) = delete;
|
||||
JsepSessionDescription& operator=(const JsepSessionDescription&) = delete;
|
||||
|
||||
// Takes ownership of `description`.
|
||||
bool Initialize(std::unique_ptr<cricket::SessionDescription> description,
|
||||
const std::string& session_id,
|
||||
|
@ -82,8 +84,6 @@ class JsepSessionDescription : public SessionDescriptionInterface {
|
|||
bool GetMediasectionIndex(const IceCandidateInterface* candidate,
|
||||
size_t* index);
|
||||
int GetMediasectionIndex(const cricket::Candidate& candidate);
|
||||
|
||||
RTC_DISALLOW_COPY_AND_ASSIGN(JsepSessionDescription);
|
||||
};
|
||||
|
||||
} // namespace webrtc
|
||||
|
|
|
@ -12,7 +12,6 @@
|
|||
|
||||
#include <type_traits>
|
||||
|
||||
#include "rtc_base/constructor_magic.h"
|
||||
#include "rtc_base/ref_counter.h"
|
||||
|
||||
namespace rtc {
|
||||
|
@ -21,6 +20,9 @@ class RefCountedBase {
|
|||
public:
|
||||
RefCountedBase() = default;
|
||||
|
||||
RefCountedBase(const RefCountedBase&) = delete;
|
||||
RefCountedBase& operator=(const RefCountedBase&) = delete;
|
||||
|
||||
void AddRef() const { ref_count_.IncRef(); }
|
||||
RefCountReleaseStatus Release() const {
|
||||
const auto status = ref_count_.DecRef();
|
||||
|
@ -39,8 +41,6 @@ class RefCountedBase {
|
|||
|
||||
private:
|
||||
mutable webrtc::webrtc_impl::RefCounter ref_count_{0};
|
||||
|
||||
RTC_DISALLOW_COPY_AND_ASSIGN(RefCountedBase);
|
||||
};
|
||||
|
||||
// Template based version of `RefCountedBase` for simple implementations that do
|
||||
|
@ -61,6 +61,9 @@ class RefCountedNonVirtual {
|
|||
public:
|
||||
RefCountedNonVirtual() = default;
|
||||
|
||||
RefCountedNonVirtual(const RefCountedNonVirtual&) = delete;
|
||||
RefCountedNonVirtual& operator=(const RefCountedNonVirtual&) = delete;
|
||||
|
||||
void AddRef() const { ref_count_.IncRef(); }
|
||||
RefCountReleaseStatus Release() const {
|
||||
// If you run into this assert, T has virtual methods. There are two
|
||||
|
@ -88,8 +91,6 @@ class RefCountedNonVirtual {
|
|||
|
||||
private:
|
||||
mutable webrtc::webrtc_impl::RefCounter ref_count_{0};
|
||||
|
||||
RTC_DISALLOW_COPY_AND_ASSIGN(RefCountedNonVirtual);
|
||||
};
|
||||
|
||||
} // namespace rtc
|
||||
|
|
|
@ -22,7 +22,6 @@
|
|||
|
||||
#include "api/scoped_refptr.h"
|
||||
#include "api/sequence_checker.h"
|
||||
#include "rtc_base/constructor_magic.h"
|
||||
#include "rtc_base/ref_count.h"
|
||||
#include "rtc_base/system/rtc_export.h"
|
||||
|
||||
|
@ -288,6 +287,9 @@ class RTC_EXPORT StatsReport {
|
|||
|
||||
~Value();
|
||||
|
||||
Value(const Value&) = delete;
|
||||
Value& operator=(const Value&) = delete;
|
||||
|
||||
// Support ref counting. Note that for performance reasons, we
|
||||
// don't use thread safe operations. Therefore, all operations
|
||||
// affecting the ref count (in practice, creation and copying of
|
||||
|
@ -358,8 +360,6 @@ class RTC_EXPORT StatsReport {
|
|||
const char* static_string_;
|
||||
Id* id_;
|
||||
} value_;
|
||||
|
||||
RTC_DISALLOW_COPY_AND_ASSIGN(Value);
|
||||
};
|
||||
|
||||
typedef rtc::scoped_refptr<Value> ValuePtr;
|
||||
|
@ -369,6 +369,9 @@ class RTC_EXPORT StatsReport {
|
|||
explicit StatsReport(const Id& id);
|
||||
~StatsReport();
|
||||
|
||||
StatsReport(const StatsReport&) = delete;
|
||||
StatsReport& operator=(const StatsReport&) = delete;
|
||||
|
||||
// Factory functions for various types of stats IDs.
|
||||
static Id NewBandwidthEstimationId();
|
||||
static Id NewTypedId(StatsType type, const std::string& id);
|
||||
|
@ -408,8 +411,6 @@ class RTC_EXPORT StatsReport {
|
|||
const Id id_;
|
||||
double timestamp_; // Time since 1970-01-01T00:00:00Z in milliseconds.
|
||||
Values values_;
|
||||
|
||||
RTC_DISALLOW_COPY_AND_ASSIGN(StatsReport);
|
||||
};
|
||||
|
||||
// Typedef for an array of const StatsReport pointers.
|
||||
|
|
|
@ -51,7 +51,6 @@
|
|||
#include "modules/utility/include/process_thread.h"
|
||||
#include "modules/video_coding/fec_controller_default.h"
|
||||
#include "rtc_base/checks.h"
|
||||
#include "rtc_base/constructor_magic.h"
|
||||
#include "rtc_base/location.h"
|
||||
#include "rtc_base/logging.h"
|
||||
#include "rtc_base/strings/string_builder.h"
|
||||
|
@ -209,6 +208,9 @@ class Call final : public webrtc::Call,
|
|||
TaskQueueFactory* task_queue_factory);
|
||||
~Call() override;
|
||||
|
||||
Call(const Call&) = delete;
|
||||
Call& operator=(const Call&) = delete;
|
||||
|
||||
// Implements webrtc::Call.
|
||||
PacketReceiver* Receiver() override;
|
||||
|
||||
|
@ -469,8 +471,6 @@ class Call final : public webrtc::Call,
|
|||
RTC_NO_UNIQUE_ADDRESS SequenceChecker sent_packet_sequence_checker_;
|
||||
absl::optional<rtc::SentPacket> last_sent_packet_
|
||||
RTC_GUARDED_BY(sent_packet_sequence_checker_);
|
||||
|
||||
RTC_DISALLOW_COPY_AND_ASSIGN(Call);
|
||||
};
|
||||
} // namespace internal
|
||||
|
||||
|
|
|
@ -23,7 +23,6 @@
|
|||
#include "api/test/simulated_network.h"
|
||||
#include "call/call.h"
|
||||
#include "call/simulated_packet_receiver.h"
|
||||
#include "rtc_base/constructor_magic.h"
|
||||
#include "rtc_base/synchronization/mutex.h"
|
||||
#include "rtc_base/thread_annotations.h"
|
||||
|
||||
|
@ -109,6 +108,9 @@ class FakeNetworkPipe : public SimulatedPacketReceiverInterface {
|
|||
|
||||
~FakeNetworkPipe() override;
|
||||
|
||||
FakeNetworkPipe(const FakeNetworkPipe&) = delete;
|
||||
FakeNetworkPipe& operator=(const FakeNetworkPipe&) = delete;
|
||||
|
||||
void SetClockOffset(int64_t offset_ms);
|
||||
|
||||
// Must not be called in parallel with DeliverPacket or Process.
|
||||
|
@ -228,8 +230,6 @@ class FakeNetworkPipe : public SimulatedPacketReceiverInterface {
|
|||
int64_t last_log_time_us_;
|
||||
|
||||
std::map<Transport*, size_t> active_transports_ RTC_GUARDED_BY(config_lock_);
|
||||
|
||||
RTC_DISALLOW_COPY_AND_ASSIGN(FakeNetworkPipe);
|
||||
};
|
||||
|
||||
} // namespace webrtc
|
||||
|
|
|
@ -14,7 +14,6 @@
|
|||
#include "absl/types/optional.h"
|
||||
#include "api/transport/bitrate_settings.h"
|
||||
#include "api/units/data_rate.h"
|
||||
#include "rtc_base/constructor_magic.h"
|
||||
|
||||
namespace webrtc {
|
||||
|
||||
|
@ -24,6 +23,10 @@ class RtpBitrateConfigurator {
|
|||
public:
|
||||
explicit RtpBitrateConfigurator(const BitrateConstraints& bitrate_config);
|
||||
~RtpBitrateConfigurator();
|
||||
|
||||
RtpBitrateConfigurator(const RtpBitrateConfigurator&) = delete;
|
||||
RtpBitrateConfigurator& operator=(const RtpBitrateConfigurator&) = delete;
|
||||
|
||||
BitrateConstraints GetConfig() const;
|
||||
|
||||
// The greater min and smaller max set by this and SetClientBitratePreferences
|
||||
|
@ -68,8 +71,6 @@ class RtpBitrateConfigurator {
|
|||
|
||||
// Bandwidth cap applied for relayed calls.
|
||||
DataRate max_bitrate_over_relay_ = DataRate::PlusInfinity();
|
||||
|
||||
RTC_DISALLOW_COPY_AND_ASSIGN(RtpBitrateConfigurator);
|
||||
};
|
||||
} // namespace webrtc
|
||||
|
||||
|
|
|
@ -32,7 +32,6 @@
|
|||
#include "modules/pacing/rtp_packet_pacer.h"
|
||||
#include "modules/pacing/task_queue_paced_sender.h"
|
||||
#include "modules/utility/include/process_thread.h"
|
||||
#include "rtc_base/constructor_magic.h"
|
||||
#include "rtc_base/network_route.h"
|
||||
#include "rtc_base/race_checker.h"
|
||||
#include "rtc_base/task_queue.h"
|
||||
|
@ -63,6 +62,10 @@ class RtpTransportControllerSend final
|
|||
const WebRtcKeyValueConfig* trials);
|
||||
~RtpTransportControllerSend() override;
|
||||
|
||||
RtpTransportControllerSend(const RtpTransportControllerSend&) = delete;
|
||||
RtpTransportControllerSend& operator=(const RtpTransportControllerSend&) =
|
||||
delete;
|
||||
|
||||
// TODO(tommi): Change to std::unique_ptr<>.
|
||||
RtpVideoSenderInterface* CreateRtpVideoSender(
|
||||
const std::map<uint32_t, RtpState>& suspended_ssrcs,
|
||||
|
@ -215,7 +218,6 @@ class RtpTransportControllerSend final
|
|||
// `task_queue_` is defined last to ensure all pending tasks are cancelled
|
||||
// and deleted before any other members.
|
||||
rtc::TaskQueue task_queue_;
|
||||
RTC_DISALLOW_COPY_AND_ASSIGN(RtpTransportControllerSend);
|
||||
};
|
||||
|
||||
} // namespace webrtc
|
||||
|
|
|
@ -35,7 +35,6 @@
|
|||
#include "modules/rtp_rtcp/source/rtp_sender_video.h"
|
||||
#include "modules/rtp_rtcp/source/rtp_sequence_number_map.h"
|
||||
#include "modules/rtp_rtcp/source/rtp_video_header.h"
|
||||
#include "rtc_base/constructor_magic.h"
|
||||
#include "rtc_base/rate_limiter.h"
|
||||
#include "rtc_base/synchronization/mutex.h"
|
||||
#include "rtc_base/thread_annotations.h"
|
||||
|
@ -89,6 +88,9 @@ class RtpVideoSender : public RtpVideoSenderInterface,
|
|||
rtc::scoped_refptr<FrameTransformerInterface> frame_transformer);
|
||||
~RtpVideoSender() override;
|
||||
|
||||
RtpVideoSender(const RtpVideoSender&) = delete;
|
||||
RtpVideoSender& operator=(const RtpVideoSender&) = delete;
|
||||
|
||||
// RtpVideoSender will only route packets if being active, all packets will be
|
||||
// dropped otherwise.
|
||||
void SetActive(bool active) RTC_LOCKS_EXCLUDED(mutex_) override;
|
||||
|
@ -209,8 +211,6 @@ class RtpVideoSender : public RtpVideoSenderInterface,
|
|||
// This map is set at construction time and never changed, but it's
|
||||
// non-trivial to make it properly const.
|
||||
std::map<uint32_t, RtpRtcpInterface*> ssrc_to_rtp_module_;
|
||||
|
||||
RTC_DISALLOW_COPY_AND_ASSIGN(RtpVideoSender);
|
||||
};
|
||||
|
||||
} // namespace webrtc
|
||||
|
|
|
@ -20,7 +20,6 @@
|
|||
#include "absl/strings/string_view.h"
|
||||
#include "rtc_base/bit_buffer.h"
|
||||
#include "rtc_base/checks.h"
|
||||
#include "rtc_base/constructor_magic.h"
|
||||
|
||||
namespace webrtc {
|
||||
|
||||
|
@ -36,6 +35,9 @@ class BitWriter final {
|
|||
RTC_DCHECK_GT(byte_count, 0);
|
||||
}
|
||||
|
||||
BitWriter(const BitWriter&) = delete;
|
||||
BitWriter& operator=(const BitWriter&) = delete;
|
||||
|
||||
void WriteBits(uint64_t val, size_t bit_count);
|
||||
|
||||
void WriteBits(absl::string_view input);
|
||||
|
@ -52,8 +54,6 @@ class BitWriter final {
|
|||
// to go anywhere near the limit, though, so this is good enough.
|
||||
size_t written_bits_;
|
||||
bool valid_;
|
||||
|
||||
RTC_DISALLOW_COPY_AND_ASSIGN(BitWriter);
|
||||
};
|
||||
|
||||
} // namespace webrtc
|
||||
|
|
|
@ -21,7 +21,6 @@
|
|||
#include "rtc_base/bit_buffer.h"
|
||||
#include "rtc_base/bitstream_reader.h"
|
||||
#include "rtc_base/checks.h"
|
||||
#include "rtc_base/constructor_magic.h"
|
||||
#include "rtc_base/logging.h"
|
||||
#include "rtc_base/numerics/safe_conversions.h"
|
||||
|
||||
|
@ -187,6 +186,9 @@ class FixedLengthDeltaEncoder final {
|
|||
absl::optional<uint64_t> base,
|
||||
const std::vector<absl::optional<uint64_t>>& values);
|
||||
|
||||
FixedLengthDeltaEncoder(const FixedLengthDeltaEncoder&) = delete;
|
||||
FixedLengthDeltaEncoder& operator=(const FixedLengthDeltaEncoder&) = delete;
|
||||
|
||||
private:
|
||||
// Calculate min/max values of unsigned/signed deltas, given the bit width
|
||||
// of all the values in the series.
|
||||
|
@ -249,8 +251,6 @@ class FixedLengthDeltaEncoder final {
|
|||
// ctor has finished running when this is constructed, so that the lower
|
||||
// bound on the buffer size would be guaranteed correct.
|
||||
std::unique_ptr<BitWriter> writer_;
|
||||
|
||||
RTC_DISALLOW_COPY_AND_ASSIGN(FixedLengthDeltaEncoder);
|
||||
};
|
||||
|
||||
// TODO(eladalon): Reduce the number of passes.
|
||||
|
@ -566,6 +566,9 @@ class FixedLengthDeltaDecoder final {
|
|||
absl::optional<uint64_t> base,
|
||||
size_t num_of_deltas);
|
||||
|
||||
FixedLengthDeltaDecoder(const FixedLengthDeltaDecoder&) = delete;
|
||||
FixedLengthDeltaDecoder& operator=(const FixedLengthDeltaDecoder&) = delete;
|
||||
|
||||
private:
|
||||
// Reads the encoding header in `input` and returns a FixedLengthDeltaDecoder
|
||||
// with the corresponding configuration, that can be used to decode the
|
||||
|
@ -619,8 +622,6 @@ class FixedLengthDeltaDecoder final {
|
|||
|
||||
// The number of values to be known to be decoded.
|
||||
const size_t num_of_deltas_;
|
||||
|
||||
RTC_DISALLOW_COPY_AND_ASSIGN(FixedLengthDeltaDecoder);
|
||||
};
|
||||
|
||||
bool FixedLengthDeltaDecoder::IsSuitableDecoderFor(const std::string& input) {
|
||||
|
|
|
@ -17,6 +17,7 @@
|
|||
#include "absl/types/optional.h"
|
||||
#include "api/video/encoded_image.h"
|
||||
#include "api/video_codecs/video_codec.h"
|
||||
#include "rtc_base/constructor_magic.h"
|
||||
#include "rtc_base/system/file_wrapper.h"
|
||||
|
||||
namespace webrtc {
|
||||
|
|
|
@ -15,7 +15,6 @@
|
|||
|
||||
#include "rtc_base/async_packet_socket.h"
|
||||
#include "rtc_base/async_tcp_socket.h"
|
||||
#include "rtc_base/constructor_magic.h"
|
||||
#include "rtc_base/socket.h"
|
||||
#include "rtc_base/socket_address.h"
|
||||
|
||||
|
@ -32,6 +31,9 @@ class AsyncStunTCPSocket : public rtc::AsyncTCPSocketBase {
|
|||
|
||||
explicit AsyncStunTCPSocket(rtc::Socket* socket);
|
||||
|
||||
AsyncStunTCPSocket(const AsyncStunTCPSocket&) = delete;
|
||||
AsyncStunTCPSocket& operator=(const AsyncStunTCPSocket&) = delete;
|
||||
|
||||
int Send(const void* pv,
|
||||
size_t cb,
|
||||
const rtc::PacketOptions& options) override;
|
||||
|
@ -42,8 +44,6 @@ class AsyncStunTCPSocket : public rtc::AsyncTCPSocketBase {
|
|||
// This method also returns the number of padding bytes needed/added to the
|
||||
// turn message. `pad_bytes` should be used only when `is_turn` is true.
|
||||
size_t GetExpectedLength(const void* data, size_t len, int* pad_bytes);
|
||||
|
||||
RTC_DISALLOW_COPY_AND_ASSIGN(AsyncStunTCPSocket);
|
||||
};
|
||||
|
||||
} // namespace cricket
|
||||
|
|
|
@ -22,7 +22,6 @@
|
|||
#include "p2p/base/ice_transport_internal.h"
|
||||
#include "rtc_base/buffer.h"
|
||||
#include "rtc_base/buffer_queue.h"
|
||||
#include "rtc_base/constructor_magic.h"
|
||||
#include "rtc_base/ssl_stream_adapter.h"
|
||||
#include "rtc_base/stream.h"
|
||||
#include "rtc_base/strings/string_builder.h"
|
||||
|
@ -40,6 +39,9 @@ class StreamInterfaceChannel : public rtc::StreamInterface {
|
|||
public:
|
||||
explicit StreamInterfaceChannel(IceTransportInternal* ice_transport);
|
||||
|
||||
StreamInterfaceChannel(const StreamInterfaceChannel&) = delete;
|
||||
StreamInterfaceChannel& operator=(const StreamInterfaceChannel&) = delete;
|
||||
|
||||
// Push in a packet; this gets pulled out from Read().
|
||||
bool OnPacketReceived(const char* data, size_t size);
|
||||
|
||||
|
@ -60,8 +62,6 @@ class StreamInterfaceChannel : public rtc::StreamInterface {
|
|||
IceTransportInternal* const ice_transport_; // owned by DtlsTransport
|
||||
rtc::StreamState state_ RTC_GUARDED_BY(sequence_checker_);
|
||||
rtc::BufferQueue packets_ RTC_GUARDED_BY(sequence_checker_);
|
||||
|
||||
RTC_DISALLOW_COPY_AND_ASSIGN(StreamInterfaceChannel);
|
||||
};
|
||||
|
||||
// This class provides a DTLS SSLStreamAdapter inside a TransportChannel-style
|
||||
|
@ -110,6 +110,9 @@ class DtlsTransport : public DtlsTransportInternal {
|
|||
|
||||
~DtlsTransport() override;
|
||||
|
||||
DtlsTransport(const DtlsTransport&) = delete;
|
||||
DtlsTransport& operator=(const DtlsTransport&) = delete;
|
||||
|
||||
webrtc::DtlsTransportState dtls_state() const override;
|
||||
const std::string& transport_name() const override;
|
||||
int component() const override;
|
||||
|
@ -248,8 +251,6 @@ class DtlsTransport : public DtlsTransportInternal {
|
|||
bool writable_ = false;
|
||||
|
||||
webrtc::RtcEventLog* const event_log_;
|
||||
|
||||
RTC_DISALLOW_COPY_AND_ASSIGN(DtlsTransport);
|
||||
};
|
||||
|
||||
} // namespace cricket
|
||||
|
|
|
@ -25,7 +25,6 @@
|
|||
#include "p2p/base/ice_transport_internal.h"
|
||||
#include "p2p/base/packet_transport_internal.h"
|
||||
#include "rtc_base/callback_list.h"
|
||||
#include "rtc_base/constructor_magic.h"
|
||||
#include "rtc_base/ssl_certificate.h"
|
||||
#include "rtc_base/ssl_fingerprint.h"
|
||||
#include "rtc_base/ssl_stream_adapter.h"
|
||||
|
@ -48,6 +47,9 @@ class DtlsTransportInternal : public rtc::PacketTransportInternal {
|
|||
public:
|
||||
~DtlsTransportInternal() override;
|
||||
|
||||
DtlsTransportInternal(const DtlsTransportInternal&) = delete;
|
||||
DtlsTransportInternal& operator=(const DtlsTransportInternal&) = delete;
|
||||
|
||||
virtual webrtc::DtlsTransportState dtls_state() const = 0;
|
||||
|
||||
virtual int component() const = 0;
|
||||
|
@ -135,7 +137,6 @@ class DtlsTransportInternal : public rtc::PacketTransportInternal {
|
|||
DtlsTransportInternal();
|
||||
|
||||
private:
|
||||
RTC_DISALLOW_COPY_AND_ASSIGN(DtlsTransportInternal);
|
||||
webrtc::CallbackList<const rtc::SSLHandshakeError>
|
||||
dtls_handshake_error_callback_list_;
|
||||
webrtc::CallbackList<DtlsTransportInternal*, const webrtc::DtlsTransportState>
|
||||
|
|
|
@ -56,7 +56,6 @@
|
|||
#include "p2p/base/transport_description.h"
|
||||
#include "rtc_base/async_packet_socket.h"
|
||||
#include "rtc_base/checks.h"
|
||||
#include "rtc_base/constructor_magic.h"
|
||||
#include "rtc_base/dscp.h"
|
||||
#include "rtc_base/network/sent_packet.h"
|
||||
#include "rtc_base/network_route.h"
|
||||
|
@ -124,6 +123,9 @@ class RTC_EXPORT P2PTransportChannel : public IceTransportInternal {
|
|||
IceControllerFactoryInterface* ice_controller_factory = nullptr);
|
||||
~P2PTransportChannel() override;
|
||||
|
||||
P2PTransportChannel(const P2PTransportChannel&) = delete;
|
||||
P2PTransportChannel& operator=(const P2PTransportChannel&) = delete;
|
||||
|
||||
// From TransportChannelImpl:
|
||||
IceTransportState GetState() const override;
|
||||
webrtc::IceTransportState GetIceTransportState() const override;
|
||||
|
@ -494,8 +496,6 @@ class RTC_EXPORT P2PTransportChannel : public IceTransportInternal {
|
|||
int64_t last_data_received_ms_ = 0;
|
||||
|
||||
IceFieldTrials field_trials_;
|
||||
|
||||
RTC_DISALLOW_COPY_AND_ASSIGN(P2PTransportChannel);
|
||||
};
|
||||
|
||||
} // namespace cricket
|
||||
|
|
|
@ -21,7 +21,6 @@
|
|||
#include "rtc_base/async_packet_socket.h"
|
||||
#include "rtc_base/async_resolver_interface.h"
|
||||
#include "rtc_base/checks.h"
|
||||
#include "rtc_base/constructor_magic.h"
|
||||
#include "rtc_base/helpers.h"
|
||||
#include "rtc_base/logging.h"
|
||||
#include "rtc_base/task_utils/to_queued_task.h"
|
||||
|
@ -69,6 +68,9 @@ class StunProber::Requester : public sigslot::has_slots<> {
|
|||
const std::vector<rtc::SocketAddress>& server_ips);
|
||||
~Requester() override;
|
||||
|
||||
Requester(const Requester&) = delete;
|
||||
Requester& operator=(const Requester&) = delete;
|
||||
|
||||
// There is no callback for SendStunRequest as the underneath socket send is
|
||||
// expected to be completed immediately. Otherwise, it'll skip this request
|
||||
// and move to the next one.
|
||||
|
@ -105,8 +107,6 @@ class StunProber::Requester : public sigslot::has_slots<> {
|
|||
int16_t num_response_received_ = 0;
|
||||
|
||||
webrtc::SequenceChecker& thread_checker_;
|
||||
|
||||
RTC_DISALLOW_COPY_AND_ASSIGN(Requester);
|
||||
};
|
||||
|
||||
StunProber::Requester::Requester(
|
||||
|
|
|
@ -17,7 +17,6 @@
|
|||
|
||||
#include "api/sequence_checker.h"
|
||||
#include "rtc_base/byte_buffer.h"
|
||||
#include "rtc_base/constructor_magic.h"
|
||||
#include "rtc_base/ip_address.h"
|
||||
#include "rtc_base/network.h"
|
||||
#include "rtc_base/socket_address.h"
|
||||
|
@ -101,6 +100,9 @@ class RTC_EXPORT StunProber : public sigslot::has_slots<> {
|
|||
const rtc::NetworkManager::NetworkList& networks);
|
||||
~StunProber() override;
|
||||
|
||||
StunProber(const StunProber&) = delete;
|
||||
StunProber& operator=(const StunProber&) = delete;
|
||||
|
||||
// Begin performing the probe test against the `servers`. If
|
||||
// `shared_socket_mode` is false, each request will be done with a new socket.
|
||||
// Otherwise, a unique socket will be used for a single round of requests
|
||||
|
@ -241,8 +243,6 @@ class RTC_EXPORT StunProber : public sigslot::has_slots<> {
|
|||
rtc::NetworkManager::NetworkList networks_;
|
||||
|
||||
webrtc::ScopedTaskSafety task_safety_;
|
||||
|
||||
RTC_DISALLOW_COPY_AND_ASSIGN(StunProber);
|
||||
};
|
||||
|
||||
} // namespace stunprober
|
||||
|
|
|
@ -18,7 +18,6 @@
|
|||
#include "api/dtmf_sender_interface.h"
|
||||
#include "api/scoped_refptr.h"
|
||||
#include "pc/proxy.h"
|
||||
#include "rtc_base/constructor_magic.h"
|
||||
#include "rtc_base/location.h"
|
||||
#include "rtc_base/ref_count.h"
|
||||
#include "rtc_base/task_utils/pending_task_safety_flag.h"
|
||||
|
@ -72,6 +71,9 @@ class DtmfSender : public DtmfSenderInterface, public sigslot::has_slots<> {
|
|||
DtmfSender(rtc::Thread* signaling_thread, DtmfProviderInterface* provider);
|
||||
virtual ~DtmfSender();
|
||||
|
||||
DtmfSender(const DtmfSender&) = delete;
|
||||
DtmfSender& operator=(const DtmfSender&) = delete;
|
||||
|
||||
private:
|
||||
DtmfSender();
|
||||
|
||||
|
@ -96,8 +98,6 @@ class DtmfSender : public DtmfSenderInterface, public sigslot::has_slots<> {
|
|||
// For cancelling the tasks which feed the DTMF provider one tone at a time.
|
||||
rtc::scoped_refptr<PendingTaskSafetyFlag> safety_flag_ RTC_GUARDED_BY(
|
||||
signaling_thread_) RTC_PT_GUARDED_BY(signaling_thread_) = nullptr;
|
||||
|
||||
RTC_DISALLOW_COPY_AND_ASSIGN(DtmfSender);
|
||||
};
|
||||
|
||||
// Define proxy for DtmfSenderInterface.
|
||||
|
|
|
@ -44,7 +44,6 @@
|
|||
#include "pc/srtp_transport.h"
|
||||
#include "pc/transport_stats.h"
|
||||
#include "rtc_base/checks.h"
|
||||
#include "rtc_base/constructor_magic.h"
|
||||
#include "rtc_base/rtc_certificate.h"
|
||||
#include "rtc_base/ssl_fingerprint.h"
|
||||
#include "rtc_base/ssl_stream_adapter.h"
|
||||
|
@ -106,6 +105,9 @@ class JsepTransport {
|
|||
|
||||
~JsepTransport();
|
||||
|
||||
JsepTransport(const JsepTransport&) = delete;
|
||||
JsepTransport& operator=(const JsepTransport&) = delete;
|
||||
|
||||
// Returns the MID of this transport. This is only used for logging.
|
||||
const std::string& mid() const { return mid_; }
|
||||
|
||||
|
@ -326,8 +328,6 @@ class JsepTransport {
|
|||
// `rtcp_dtls_transport_` is destroyed. The JsepTransportController will
|
||||
// receive the callback and update the aggregate transport states.
|
||||
std::function<void()> rtcp_mux_active_callback_;
|
||||
|
||||
RTC_DISALLOW_COPY_AND_ASSIGN(JsepTransport);
|
||||
};
|
||||
|
||||
} // namespace cricket
|
||||
|
|
|
@ -58,7 +58,6 @@
|
|||
#include "pc/transport_stats.h"
|
||||
#include "rtc_base/callback_list.h"
|
||||
#include "rtc_base/checks.h"
|
||||
#include "rtc_base/constructor_magic.h"
|
||||
#include "rtc_base/copy_on_write_buffer.h"
|
||||
#include "rtc_base/helpers.h"
|
||||
#include "rtc_base/ref_counted_object.h"
|
||||
|
@ -150,6 +149,9 @@ class JsepTransportController : public sigslot::has_slots<> {
|
|||
Config config);
|
||||
virtual ~JsepTransportController();
|
||||
|
||||
JsepTransportController(const JsepTransportController&) = delete;
|
||||
JsepTransportController& operator=(const JsepTransportController&) = delete;
|
||||
|
||||
// The main method to be called; applies a description at the transport
|
||||
// level, creating/destroying transport objects as needed and updating their
|
||||
// properties. This includes RTP, DTLS, and ICE (but not SCTP). At least not
|
||||
|
@ -478,8 +480,6 @@ class JsepTransportController : public sigslot::has_slots<> {
|
|||
rtc::scoped_refptr<rtc::RTCCertificate> certificate_;
|
||||
|
||||
BundleManager bundles_;
|
||||
|
||||
RTC_DISALLOW_COPY_AND_ASSIGN(JsepTransportController);
|
||||
};
|
||||
|
||||
} // namespace webrtc
|
||||
|
|
|
@ -15,7 +15,6 @@
|
|||
|
||||
#include "api/scoped_refptr.h"
|
||||
#include "api/sequence_checker.h"
|
||||
#include "rtc_base/constructor_magic.h"
|
||||
#include "rtc_base/synchronization/mutex.h"
|
||||
|
||||
// Forward declaration to avoid pulling in libsrtp headers here
|
||||
|
@ -35,6 +34,9 @@ class SrtpSession {
|
|||
SrtpSession();
|
||||
~SrtpSession();
|
||||
|
||||
SrtpSession(const SrtpSession&) = delete;
|
||||
SrtpSession& operator=(const SrtpSession&) = delete;
|
||||
|
||||
// Configures the session for sending data using the specified
|
||||
// cipher-suite and key. Receiving must be done by a separate session.
|
||||
bool SetSend(int cs,
|
||||
|
@ -141,7 +143,6 @@ class SrtpSession {
|
|||
bool external_auth_enabled_ = false;
|
||||
int decryption_failure_count_ = 0;
|
||||
bool dump_plain_rtp_ = false;
|
||||
RTC_DISALLOW_COPY_AND_ASSIGN(SrtpSession);
|
||||
};
|
||||
|
||||
} // namespace cricket
|
||||
|
|
|
@ -20,7 +20,6 @@
|
|||
#include "api/video/video_source_interface.h"
|
||||
#include "media/base/video_broadcaster.h"
|
||||
#include "pc/video_track_source.h"
|
||||
#include "rtc_base/constructor_magic.h"
|
||||
#include "rtc_base/synchronization/mutex.h"
|
||||
#include "rtc_base/system/no_unique_address.h"
|
||||
#include "rtc_base/thread_annotations.h"
|
||||
|
@ -45,6 +44,9 @@ class VideoRtpTrackSource : public VideoTrackSource {
|
|||
|
||||
explicit VideoRtpTrackSource(Callback* callback);
|
||||
|
||||
VideoRtpTrackSource(const VideoRtpTrackSource&) = delete;
|
||||
VideoRtpTrackSource& operator=(const VideoRtpTrackSource&) = delete;
|
||||
|
||||
// Call before the object implementing Callback finishes it's destructor. No
|
||||
// more callbacks will be fired after completion. Must be called on the
|
||||
// worker thread
|
||||
|
@ -83,8 +85,6 @@ class VideoRtpTrackSource : public VideoTrackSource {
|
|||
std::vector<rtc::VideoSinkInterface<RecordableEncodedFrame>*> encoded_sinks_
|
||||
RTC_GUARDED_BY(mu_);
|
||||
Callback* callback_ RTC_GUARDED_BY(worker_sequence_checker_);
|
||||
|
||||
RTC_DISALLOW_COPY_AND_ASSIGN(VideoRtpTrackSource);
|
||||
};
|
||||
|
||||
} // namespace webrtc
|
||||
|
|
|
@ -26,7 +26,6 @@
|
|||
#include "pc/channel_manager.h"
|
||||
#include "pc/media_session.h"
|
||||
#include "pc/sdp_state_provider.h"
|
||||
#include "rtc_base/constructor_magic.h"
|
||||
#include "rtc_base/message_handler.h"
|
||||
#include "rtc_base/rtc_certificate.h"
|
||||
#include "rtc_base/rtc_certificate_generator.h"
|
||||
|
@ -92,6 +91,11 @@ class WebRtcSessionDescriptionFactory : public rtc::MessageHandler,
|
|||
on_certificate_ready);
|
||||
virtual ~WebRtcSessionDescriptionFactory();
|
||||
|
||||
WebRtcSessionDescriptionFactory(const WebRtcSessionDescriptionFactory&) =
|
||||
delete;
|
||||
WebRtcSessionDescriptionFactory& operator=(
|
||||
const WebRtcSessionDescriptionFactory&) = delete;
|
||||
|
||||
static void CopyCandidatesFromSessionDescription(
|
||||
const SessionDescriptionInterface* source_desc,
|
||||
const std::string& content_name,
|
||||
|
@ -159,8 +163,6 @@ class WebRtcSessionDescriptionFactory : public rtc::MessageHandler,
|
|||
|
||||
std::function<void(const rtc::scoped_refptr<rtc::RTCCertificate>&)>
|
||||
on_certificate_ready_;
|
||||
|
||||
RTC_DISALLOW_COPY_AND_ASSIGN(WebRtcSessionDescriptionFactory);
|
||||
};
|
||||
} // namespace webrtc
|
||||
|
||||
|
|
|
@ -11,7 +11,6 @@
|
|||
|
||||
#include <algorithm>
|
||||
|
||||
#include "rtc_base/constructor_magic.h"
|
||||
#include "rtc_base/synchronization/mutex.h"
|
||||
#include "rtc_base/thread_annotations.h"
|
||||
|
||||
|
@ -35,6 +34,9 @@ class RtcHistogram {
|
|||
RTC_DCHECK_GT(bucket_count, 0);
|
||||
}
|
||||
|
||||
RtcHistogram(const RtcHistogram&) = delete;
|
||||
RtcHistogram& operator=(const RtcHistogram&) = delete;
|
||||
|
||||
void Add(int sample) {
|
||||
sample = std::min(sample, max_);
|
||||
sample = std::max(sample, min_ - 1); // Underflow bucket.
|
||||
|
@ -99,8 +101,6 @@ class RtcHistogram {
|
|||
const int min_;
|
||||
const int max_;
|
||||
SampleInfo info_ RTC_GUARDED_BY(mutex_);
|
||||
|
||||
RTC_DISALLOW_COPY_AND_ASSIGN(RtcHistogram);
|
||||
};
|
||||
|
||||
class RtcHistogramMap {
|
||||
|
@ -108,6 +108,9 @@ class RtcHistogramMap {
|
|||
RtcHistogramMap() {}
|
||||
~RtcHistogramMap() {}
|
||||
|
||||
RtcHistogramMap(const RtcHistogramMap&) = delete;
|
||||
RtcHistogramMap& operator=(const RtcHistogramMap&) = delete;
|
||||
|
||||
Histogram* GetCountsHistogram(const std::string& name,
|
||||
int min,
|
||||
int max,
|
||||
|
@ -178,8 +181,6 @@ class RtcHistogramMap {
|
|||
mutable Mutex mutex_;
|
||||
std::map<std::string, std::unique_ptr<RtcHistogram>> map_
|
||||
RTC_GUARDED_BY(mutex_);
|
||||
|
||||
RTC_DISALLOW_COPY_AND_ASSIGN(RtcHistogramMap);
|
||||
};
|
||||
|
||||
// RtcHistogramMap is allocated upon call to Enable().
|
||||
|
|
|
@ -26,6 +26,7 @@
|
|||
#include "api/test/network_emulation_manager.h"
|
||||
#include "api/test/simulated_network.h"
|
||||
#include "api/units/timestamp.h"
|
||||
#include "rtc_base/constructor_magic.h"
|
||||
#include "rtc_base/copy_on_write_buffer.h"
|
||||
#include "rtc_base/network.h"
|
||||
#include "rtc_base/network_constants.h"
|
||||
|
|
Loading…
Reference in a new issue