20
20
* Represents the ice transport policy. This exposes the same states in C++,
21
21
* which include one more state than what exists in the W3C spec.
22
22
*/
23
- typedef NS_ENUM (NSInteger , RTCIceTransportPolicy) {
24
- RTCIceTransportPolicyNone,
25
- RTCIceTransportPolicyRelay,
26
- RTCIceTransportPolicyNoHost,
27
- RTCIceTransportPolicyAll
23
+ typedef NS_ENUM (NSInteger , RTC_OBJC_TYPE( RTCIceTransportPolicy) ) {
24
+ RTC_OBJC_TYPE ( RTCIceTransportPolicyNone) ,
25
+ RTC_OBJC_TYPE ( RTCIceTransportPolicyRelay) ,
26
+ RTC_OBJC_TYPE ( RTCIceTransportPolicyNoHost) ,
27
+ RTC_OBJC_TYPE ( RTCIceTransportPolicyAll)
28
28
};
29
29
30
30
/* * Represents the bundle policy. */
31
- typedef NS_ENUM (NSInteger , RTCBundlePolicy) {
32
- RTCBundlePolicyBalanced,
33
- RTCBundlePolicyMaxCompat,
34
- RTCBundlePolicyMaxBundle
31
+ typedef NS_ENUM (NSInteger , RTC_OBJC_TYPE( RTCBundlePolicy) ) {
32
+ RTC_OBJC_TYPE ( RTCBundlePolicyBalanced) ,
33
+ RTC_OBJC_TYPE ( RTCBundlePolicyMaxCompat) ,
34
+ RTC_OBJC_TYPE ( RTCBundlePolicyMaxBundle)
35
35
};
36
36
37
37
/* * Represents the rtcp mux policy. */
38
- typedef NS_ENUM (NSInteger , RTCRtcpMuxPolicy) { RTCRtcpMuxPolicyNegotiate, RTCRtcpMuxPolicyRequire };
38
+ typedef NS_ENUM (NSInteger , RTC_OBJC_TYPE(RTCRtcpMuxPolicy)) {
39
+ RTC_OBJC_TYPE (RTCRtcpMuxPolicyNegotiate),
40
+ RTC_OBJC_TYPE (RTCRtcpMuxPolicyRequire)
41
+ };
39
42
40
43
/* * Represents the tcp candidate policy. */
41
- typedef NS_ENUM (NSInteger , RTCTcpCandidatePolicy) {
42
- RTCTcpCandidatePolicyEnabled,
43
- RTCTcpCandidatePolicyDisabled
44
+ typedef NS_ENUM (NSInteger , RTC_OBJC_TYPE( RTCTcpCandidatePolicy) ) {
45
+ RTC_OBJC_TYPE ( RTCTcpCandidatePolicyEnabled) ,
46
+ RTC_OBJC_TYPE ( RTCTcpCandidatePolicyDisabled)
44
47
};
45
48
46
49
/* * Represents the candidate network policy. */
47
- typedef NS_ENUM (NSInteger , RTCCandidateNetworkPolicy) {
48
- RTCCandidateNetworkPolicyAll,
49
- RTCCandidateNetworkPolicyLowCost
50
+ typedef NS_ENUM (NSInteger , RTC_OBJC_TYPE( RTCCandidateNetworkPolicy) ) {
51
+ RTC_OBJC_TYPE ( RTCCandidateNetworkPolicyAll) ,
52
+ RTC_OBJC_TYPE ( RTCCandidateNetworkPolicyLowCost)
50
53
};
51
54
52
55
/* * Represents the continual gathering policy. */
53
- typedef NS_ENUM (NSInteger , RTCContinualGatheringPolicy) {
54
- RTCContinualGatheringPolicyGatherOnce,
55
- RTCContinualGatheringPolicyGatherContinually
56
+ typedef NS_ENUM (NSInteger , RTC_OBJC_TYPE( RTCContinualGatheringPolicy) ) {
57
+ RTC_OBJC_TYPE ( RTCContinualGatheringPolicyGatherOnce) ,
58
+ RTC_OBJC_TYPE ( RTCContinualGatheringPolicyGatherContinually)
56
59
};
57
60
58
61
/* * Represents the encryption key type. */
59
- typedef NS_ENUM (NSInteger , RTCEncryptionKeyType) {
60
- RTCEncryptionKeyTypeRSA,
61
- RTCEncryptionKeyTypeECDSA,
62
+ typedef NS_ENUM (NSInteger , RTC_OBJC_TYPE( RTCEncryptionKeyType) ) {
63
+ RTC_OBJC_TYPE ( RTCEncryptionKeyTypeRSA) ,
64
+ RTC_OBJC_TYPE ( RTCEncryptionKeyTypeECDSA) ,
62
65
};
63
66
64
67
/* * Represents the chosen SDP semantics for the RTCPeerConnection. */
65
- typedef NS_ENUM (NSInteger , RTCSdpSemantics) {
68
+ typedef NS_ENUM (NSInteger , RTC_OBJC_TYPE( RTCSdpSemantics) ) {
66
69
// TODO(https://crbug.com/webrtc/13528): Remove support for Plan B.
67
- RTCSdpSemanticsPlanB,
68
- RTCSdpSemanticsUnifiedPlan,
70
+ RTC_OBJC_TYPE ( RTCSdpSemanticsPlanB) ,
71
+ RTC_OBJC_TYPE ( RTCSdpSemanticsUnifiedPlan) ,
69
72
};
70
73
71
74
NS_ASSUME_NONNULL_BEGIN
@@ -86,16 +89,16 @@ RTC_OBJC_EXPORT
86
89
87
90
/* * Which candidates the ICE agent is allowed to use. The W3C calls it
88
91
* `iceTransportPolicy`, while in C++ it is called `type`. */
89
- @property (nonatomic , assign ) RTCIceTransportPolicy iceTransportPolicy;
92
+ @property (nonatomic , assign ) RTC_OBJC_TYPE( RTCIceTransportPolicy) iceTransportPolicy;
90
93
91
94
/* * The media-bundling policy to use when gathering ICE candidates. */
92
- @property (nonatomic , assign ) RTCBundlePolicy bundlePolicy;
95
+ @property (nonatomic , assign ) RTC_OBJC_TYPE( RTCBundlePolicy) bundlePolicy;
93
96
94
97
/* * The rtcp-mux policy to use when gathering ICE candidates. */
95
- @property (nonatomic , assign ) RTCRtcpMuxPolicy rtcpMuxPolicy;
96
- @property (nonatomic , assign ) RTCTcpCandidatePolicy tcpCandidatePolicy;
97
- @property (nonatomic , assign ) RTCCandidateNetworkPolicy candidateNetworkPolicy;
98
- @property (nonatomic , assign ) RTCContinualGatheringPolicy continualGatheringPolicy;
98
+ @property (nonatomic , assign ) RTC_OBJC_TYPE( RTCRtcpMuxPolicy) rtcpMuxPolicy;
99
+ @property (nonatomic , assign ) RTC_OBJC_TYPE( RTCTcpCandidatePolicy) tcpCandidatePolicy;
100
+ @property (nonatomic , assign ) RTC_OBJC_TYPE( RTCCandidateNetworkPolicy) candidateNetworkPolicy;
101
+ @property (nonatomic , assign ) RTC_OBJC_TYPE( RTCContinualGatheringPolicy) continualGatheringPolicy;
99
102
100
103
/* * If set to YES, don't gather IPv6 ICE candidates on Wi-Fi.
101
104
* Only intended to be used on specific devices. Certain phones disable IPv6
@@ -125,7 +128,7 @@ RTC_OBJC_EXPORT
125
128
@property (nonatomic , assign ) int iceBackupCandidatePairPingInterval;
126
129
127
130
/* * Key type used to generate SSL identity. Default is ECDSA. */
128
- @property (nonatomic , assign ) RTCEncryptionKeyType keyType;
131
+ @property (nonatomic , assign ) RTC_OBJC_TYPE( RTCEncryptionKeyType) keyType;
129
132
130
133
/* * ICE candidate pool size as defined in JSEP. Default is 0. */
131
134
@property (nonatomic , assign ) int iceCandidatePoolSize;
@@ -176,7 +179,7 @@ RTC_OBJC_EXPORT
176
179
* the section. This will also cause RTCPeerConnection to ignore all but the
177
180
* first m= section of the same media type.
178
181
*/
179
- @property (nonatomic , assign ) RTCSdpSemantics sdpSemantics;
182
+ @property (nonatomic , assign ) RTC_OBJC_TYPE( RTCSdpSemantics) sdpSemantics;
180
183
181
184
/* * Actively reset the SRTP parameters when the DTLS transports underneath are
182
185
* changed after offer/answer negotiation. This is only intended to be a
0 commit comments