Fix clang style errors in api/jsep.h

In this case, clang style forbids inline definitions for virtual
functions.

Bug: webrtc:163
Change-Id: Id924cadb0a1d32e12cdb691c57fbda5f5b022638
Reviewed-on: https://webrtc-review.googlesource.com/29441
Reviewed-by: Peter Thatcher <pthatcher@webrtc.org>
Reviewed-by: Zhi Huang <zhihuang@webrtc.org>
Commit-Queue: Steve Anton <steveanton@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#21126}
This commit is contained in:
Steve Anton
2017-12-05 12:50:26 -08:00
committed by Commit Bot
parent 91bd263006
commit 845bb73196
3 changed files with 29 additions and 4 deletions

View File

@ -41,6 +41,7 @@ rtc_static_library("libjingle_peerconnection_api") {
"cryptoparams.h", "cryptoparams.h",
"datachannelinterface.h", "datachannelinterface.h",
"dtmfsenderinterface.h", "dtmfsenderinterface.h",
"jsep.cc",
"jsep.h", "jsep.h",
"jsepicecandidate.h", "jsepicecandidate.h",
"jsepsessiondescription.h", "jsepsessiondescription.h",

24
api/jsep.cc Normal file
View File

@ -0,0 +1,24 @@
/*
* Copyright 2017 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.
*/
#include "api/jsep.h"
namespace webrtc {
std::string IceCandidateInterface::server_url() const {
return "";
}
size_t SessionDescriptionInterface::RemoveCandidates(
const std::vector<cricket::Candidate>& candidates) {
return 0;
}
} // namespace webrtc

View File

@ -64,7 +64,7 @@ class IceCandidateInterface {
// The URL of the ICE server which this candidate was gathered from. // The URL of the ICE server which this candidate was gathered from.
// TODO(zhihuang): Remove the default implementation once the subclasses // TODO(zhihuang): Remove the default implementation once the subclasses
// implement this method. // implement this method.
virtual std::string server_url() const { return ""; } virtual std::string server_url() const;
// Creates a SDP-ized form of this candidate. // Creates a SDP-ized form of this candidate.
virtual bool ToString(std::string* out) const = 0; virtual bool ToString(std::string* out) const = 0;
}; };
@ -155,7 +155,7 @@ class SessionDescriptionInterface {
// //
// Returns the number of candidates removed. // Returns the number of candidates removed.
virtual size_t RemoveCandidates( virtual size_t RemoveCandidates(
const std::vector<cricket::Candidate>& candidates) { return 0; } const std::vector<cricket::Candidate>& candidates);
// Returns the number of m= sections in the session description. // Returns the number of m= sections in the session description.
virtual size_t number_of_mediasections() const = 0; virtual size_t number_of_mediasections() const = 0;
@ -200,7 +200,7 @@ class CreateSessionDescriptionObserver : public rtc::RefCountInterface {
virtual void OnFailure(const std::string& error) = 0; virtual void OnFailure(const std::string& error) = 0;
protected: protected:
~CreateSessionDescriptionObserver() {} ~CreateSessionDescriptionObserver() override = default;
}; };
// SetLocalDescription and SetRemoteDescription callback interface. // SetLocalDescription and SetRemoteDescription callback interface.
@ -210,7 +210,7 @@ class SetSessionDescriptionObserver : public rtc::RefCountInterface {
virtual void OnFailure(const std::string& error) = 0; virtual void OnFailure(const std::string& error) = 0;
protected: protected:
~SetSessionDescriptionObserver() {} ~SetSessionDescriptionObserver() override = default;
}; };
} // namespace webrtc } // namespace webrtc