Add CreateSessionDescription overload which takes a cricket::SessionDescription
This gives clients a way to create a SessionDescriptionInterface
from a parsed cricket::SessionDescription other than depending on
JsepSessionDescription.
Bug: webrtc:9544
Change-Id: I3eec87b24aa005e6cbc4a018ad452c0d6823435d
Reviewed-on: https://webrtc-review.googlesource.com/90382
Reviewed-by: Seth Hampson <shampson@webrtc.org>
Commit-Queue: Steve Anton <steveanton@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#24105}
diff --git a/api/jsep.h b/api/jsep.h
index cbc0a6c..4d4bcc0 100644
--- a/api/jsep.h
+++ b/api/jsep.h
@@ -197,6 +197,14 @@
const std::string& sdp,
SdpParseError* error_out);
+// Creates a SessionDescriptionInterface based on a parsed SDP structure and the
+// given type, ID and version.
+std::unique_ptr<SessionDescriptionInterface> CreateSessionDescription(
+ SdpType type,
+ const std::string& session_id,
+ const std::string& session_version,
+ std::unique_ptr<cricket::SessionDescription> description);
+
// CreateOffer and CreateAnswer callback interface.
class CreateSessionDescriptionObserver : public rtc::RefCountInterface {
public: