diff options
author | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-05-15 03:35:49 +0000 |
---|---|---|
committer | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-05-15 03:35:49 +0000 |
commit | d8bbc7858622b6d9c278469aab701ca0b609cddf (patch) | |
tree | eff41dc61d9f714852212739e6b3738b82a2af87 /third_party/libwebrtc/test/network/network_emulation.h | |
parent | Releasing progress-linux version 125.0.3-1~progress7.99u1. (diff) | |
download | firefox-d8bbc7858622b6d9c278469aab701ca0b609cddf.tar.xz firefox-d8bbc7858622b6d9c278469aab701ca0b609cddf.zip |
Merging upstream version 126.0.
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'third_party/libwebrtc/test/network/network_emulation.h')
-rw-r--r-- | third_party/libwebrtc/test/network/network_emulation.h | 16 |
1 files changed, 9 insertions, 7 deletions
diff --git a/third_party/libwebrtc/test/network/network_emulation.h b/third_party/libwebrtc/test/network/network_emulation.h index dffabafa7c..20705197be 100644 --- a/third_party/libwebrtc/test/network/network_emulation.h +++ b/third_party/libwebrtc/test/network/network_emulation.h @@ -19,10 +19,12 @@ #include <utility> #include <vector> +#include "absl/base/nullability.h" #include "absl/types/optional.h" #include "api/array_view.h" #include "api/numerics/samples_stats_counter.h" #include "api/sequence_checker.h" +#include "api/task_queue/task_queue_base.h" #include "api/test/network_emulation/network_emulation_interfaces.h" #include "api/test/network_emulation_manager.h" #include "api/test/simulated_network.h" @@ -145,7 +147,7 @@ class EmulatedNetworkNodeStatsBuilder { class LinkEmulation : public EmulatedNetworkReceiverInterface { public: LinkEmulation(Clock* clock, - rtc::TaskQueue* task_queue, + absl::Nonnull<TaskQueueBase*> task_queue, std::unique_ptr<NetworkBehaviorInterface> network_behavior, EmulatedNetworkReceiverInterface* receiver, EmulatedNetworkStatsGatheringMode stats_gathering_mode) @@ -168,7 +170,7 @@ class LinkEmulation : public EmulatedNetworkReceiverInterface { void Process(Timestamp at_time) RTC_RUN_ON(task_queue_); Clock* const clock_; - rtc::TaskQueue* const task_queue_; + const absl::Nonnull<TaskQueueBase*> task_queue_; const std::unique_ptr<NetworkBehaviorInterface> network_behavior_ RTC_GUARDED_BY(task_queue_); EmulatedNetworkReceiverInterface* const receiver_; @@ -186,7 +188,7 @@ class LinkEmulation : public EmulatedNetworkReceiverInterface { // the packet will be silently dropped. class NetworkRouterNode : public EmulatedNetworkReceiverInterface { public: - explicit NetworkRouterNode(rtc::TaskQueue* task_queue); + explicit NetworkRouterNode(absl::Nonnull<TaskQueueBase*> task_queue); void OnPacketReceived(EmulatedIpPacket packet) override; void SetReceiver(const rtc::IPAddress& dest_ip, @@ -200,7 +202,7 @@ class NetworkRouterNode : public EmulatedNetworkReceiverInterface { void SetFilter(std::function<bool(const EmulatedIpPacket&)> filter); private: - rtc::TaskQueue* const task_queue_; + const absl::Nonnull<TaskQueueBase*> task_queue_; absl::optional<EmulatedNetworkReceiverInterface*> default_receiver_ RTC_GUARDED_BY(task_queue_); std::map<rtc::IPAddress, EmulatedNetworkReceiverInterface*> routing_ @@ -224,7 +226,7 @@ class EmulatedNetworkNode : public EmulatedNetworkReceiverInterface { // they are ready. EmulatedNetworkNode( Clock* clock, - rtc::TaskQueue* task_queue, + absl::Nonnull<TaskQueueBase*> task_queue, std::unique_ptr<NetworkBehaviorInterface> network_behavior, EmulatedNetworkStatsGatheringMode stats_gathering_mode); ~EmulatedNetworkNode() override; @@ -283,7 +285,7 @@ class EmulatedEndpointImpl : public EmulatedEndpoint { EmulatedEndpointImpl(const Options& options, bool is_enabled, - rtc::TaskQueue* task_queue, + absl::Nonnull<TaskQueueBase*> task_queue, Clock* clock); ~EmulatedEndpointImpl() override; @@ -341,7 +343,7 @@ class EmulatedEndpointImpl : public EmulatedEndpoint { const Options options_; bool is_enabled_ RTC_GUARDED_BY(enabled_state_checker_); Clock* const clock_; - rtc::TaskQueue* const task_queue_; + const absl::Nonnull<TaskQueueBase*> task_queue_; std::unique_ptr<rtc::Network> network_; NetworkRouterNode router_; |