From 9f25392f69285dc35a796291cf23fbac393f8bd2 Mon Sep 17 00:00:00 2001
From: xia-chu <771730766@qq.com>
Date: Fri, 7 May 2021 14:01:24 +0800
Subject: [PATCH] =?UTF-8?q?=E7=B2=BE=E7=AE=80api=E5=91=BD=E5=90=8D?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
webrtc/RtpExt.cpp | 4 ++--
webrtc/RtpExt.h | 4 ++--
2 files changed, 4 insertions(+), 4 deletions(-)
diff --git a/webrtc/RtpExt.cpp b/webrtc/RtpExt.cpp
index 83ce7bbb..1be988a9 100644
--- a/webrtc/RtpExt.cpp
+++ b/webrtc/RtpExt.cpp
@@ -181,7 +181,7 @@ static unordered_map s_type_to_url = {RTP_EXT_M
static unordered_map s_url_to_type = {RTP_EXT_MAP(XX)};
#undef XX
-RtpExtType RtpExt::getRtpExtType(const string &url) {
+RtpExtType RtpExt::getExtType(const string &url) {
auto it = s_url_to_type.find(url);
if (it == s_url_to_type.end()) {
throw std::invalid_argument(string("未识别的rtp ext url类型:") + url);
@@ -189,7 +189,7 @@ RtpExtType RtpExt::getRtpExtType(const string &url) {
return it->second;
}
-const string &RtpExt::getRtpExtUrl(RtpExtType type) {
+const string &RtpExt::getExtUrl(RtpExtType type) {
auto it = s_type_to_url.find(type);
if (it == s_type_to_url.end()) {
throw std::invalid_argument(string("未识别的rtp ext类型:") + to_string((int) type));
diff --git a/webrtc/RtpExt.h b/webrtc/RtpExt.h
index c89ee560..05aa85c5 100644
--- a/webrtc/RtpExt.h
+++ b/webrtc/RtpExt.h
@@ -43,8 +43,8 @@ class RtpExt : public std::string {
public:
~RtpExt() = default;
static map getExtValue(const RtpHeader *header, const RtcMedia &media);
- static RtpExtType getRtpExtType(const string &url);
- static const string& getRtpExtUrl(RtpExtType type);
+ static RtpExtType getExtType(const string &url);
+ static const string& getExtUrl(RtpExtType type);
private:
RtpExt(RtpExtType type, const char *str, size_t size) : std::string(str, size), _type(type) {}