Adopt absl::string_view in modules/rtp_rtcp

Bug: webrtc:13579
Change-Id: Ic4e1431bedc69492358cb2e3749b50a941306f44
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/262250
Reviewed-by: Erik Språng <sprang@webrtc.org>
Commit-Queue: Ali Tofigh <alito@webrtc.org>
Cr-Commit-Position: refs/heads/main@{#36887}
This commit is contained in:
Ali Tofigh
2022-05-13 11:42:16 +02:00
committed by WebRTC LUCI CQ
parent 76d84f122e
commit d14e8894fc
20 changed files with 64 additions and 48 deletions

View File

@ -15,6 +15,7 @@
#include <string>
#include <vector>
#include "absl/strings/string_view.h"
#include "absl/types/optional.h"
#include "api/field_trials_view.h"
#include "api/frame_transformer_interface.h"
@ -255,12 +256,12 @@ class RtpRtcpInterface : public RtcpFeedbackSenderInterface {
// RIDs are used to identify an RTP stream if SSRCs are not negotiated.
// If the RID and Repaired RID extensions are not registered, the RID will
// not be sent.
virtual void SetRid(const std::string& rid) = 0;
virtual void SetRid(absl::string_view rid) = 0;
// Sets the value for sending in the MID RTP header extension.
// The MID RTP header extension should be registered for this to do anything.
// Once set, this value can not be changed or removed.
virtual void SetMid(const std::string& mid) = 0;
virtual void SetMid(absl::string_view mid) = 0;
// Sets CSRC.
// `csrcs` - vector of CSRCs
@ -373,7 +374,7 @@ class RtpRtcpInterface : public RtcpFeedbackSenderInterface {
// Sets RTCP CName (i.e unique identifier).
// Returns -1 on failure else 0.
virtual int32_t SetCNAME(const char* cname) = 0;
virtual int32_t SetCNAME(absl::string_view cname) = 0;
// Returns remote NTP.
// Returns -1 on failure else 0.