Chromium Code Reviews| Index: webrtc/api/ortc/sessiondescription.h |
| diff --git a/webrtc/api/ortc/sessiondescription.h b/webrtc/api/ortc/sessiondescription.h |
| new file mode 100644 |
| index 0000000000000000000000000000000000000000..b0893a6d2e918b0e0d866d3bf0d60b65fe3273a1 |
| --- /dev/null |
| +++ b/webrtc/api/ortc/sessiondescription.h |
| @@ -0,0 +1,39 @@ |
| +/* |
| + * 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. |
| + */ |
| + |
| +#ifndef WEBRTC_API_ORTC_SESSIONDESCRIPTION_H_ |
| +#define WEBRTC_API_ORTC_SESSIONDESCRIPTION_H_ |
| + |
| +#include <string> |
| + |
| +namespace webrtc { |
| + |
| +// A structured representation of an SDP message. |
| +class SessionDescription { |
| + public: |
| + SessionDescription(std::string session_id, std::string session_version) |
| + : session_id_(session_id), session_version_(session_version) {} |
|
Taylor Brandstetter
2017/03/11 00:24:29
Should be session_id_(std::move(session_id)) to en
Zhi Huang
2017/03/11 01:20:39
Done.
|
| + |
| + std::string session_id() const { return session_id_; } |
|
Taylor Brandstetter
2017/03/11 00:24:29
Would be nice to add comments for where these thin
Taylor Brandstetter
2017/03/11 00:24:29
These could return const refs.
Zhi Huang
2017/03/11 01:20:39
Done.
Zhi Huang
2017/03/11 01:20:39
Done.
|
| + void set_session_id(std::string session_id) { session_id_ = session_id; } |
| + |
| + std::string session_version() const { return session_version_; } |
| + void set_session_version(std::string session_version) { |
| + session_version_ = session_version; |
| + } |
| + |
| + private: |
| + std::string session_id_; |
| + std::string session_version_; |
| +}; |
| + |
| +} // namespace webrtc |
| + |
| +#endif // WEBRTC_API_ORTC_SESSIONDESCRIPTION_H_ |