Harald Alvestrand | 5fc28b1 | 2019-05-13 13:36:16 +0200 | [diff] [blame] | 1 | /* |
| 2 | * Copyright 2019 The WebRTC project authors. All Rights Reserved. |
| 3 | * |
| 4 | * Use of this source code is governed by a BSD-style license |
| 5 | * that can be found in the LICENSE file in the root of the source |
| 6 | * tree. An additional intellectual property rights grant can be found |
| 7 | * in the file PATENTS. All contributing project authors may |
| 8 | * be found in the AUTHORS file in the root of the source tree. |
| 9 | */ |
| 10 | |
| 11 | #ifndef PC_MEDIA_PROTOCOL_NAMES_H_ |
| 12 | #define PC_MEDIA_PROTOCOL_NAMES_H_ |
| 13 | |
| 14 | #include <string> |
| 15 | |
| 16 | namespace cricket { |
| 17 | |
| 18 | // Names or name prefixes of protocols as defined by SDP specifications. |
| 19 | extern const char kMediaProtocolRtpPrefix[]; |
| 20 | extern const char kMediaProtocolSctp[]; |
| 21 | extern const char kMediaProtocolDtlsSctp[]; |
| 22 | extern const char kMediaProtocolUdpDtlsSctp[]; |
| 23 | extern const char kMediaProtocolTcpDtlsSctp[]; |
| 24 | |
| 25 | bool IsDtlsSctp(const std::string& protocol); |
| 26 | bool IsPlainSctp(const std::string& protocol); |
| 27 | |
| 28 | // Returns true if the given media section protocol indicates use of RTP. |
| 29 | bool IsRtpProtocol(const std::string& protocol); |
| 30 | // Returns true if the given media section protocol indicates use of SCTP. |
| 31 | bool IsSctpProtocol(const std::string& protocol); |
| 32 | |
| 33 | } // namespace cricket |
| 34 | |
| 35 | #endif // PC_MEDIA_PROTOCOL_NAMES_H_ |