LeviLamina
Loading...
Searching...
No Matches
PeerConnectionInterface.h
1#pragma once
2
3#include "mc/_HeaderOutputPredefine.h"
4
5// auto generated inclusion list
6#include "mc/external/webrtc/AdapterType.h"
7#include "mc/external/webrtc/CryptoOptions.h"
8#include "mc/external/webrtc/MediaConfig.h"
9#include "mc/external/webrtc/MediaType.h"
10#include "mc/external/webrtc/PortPrunePolicy.h"
11#include "mc/external/webrtc/RTCErrorOr.h"
12#include "mc/external/webrtc/RefCountInterface.h"
13#include "mc/external/webrtc/SdpSemantics.h"
14#include "mc/external/webrtc/TimeDelta.h"
15#include "mc/external/webrtc/VpnPreference.h"
16#include "mc/external/webrtc/scoped_refptr.h"
17
18// auto generated forward declare list
19// clang-format off
20namespace webrtc { class Candidate; }
21namespace webrtc { class CreateSessionDescriptionObserver; }
22namespace webrtc { class DataChannelEventObserverInterface; }
23namespace webrtc { class DataChannelInterface; }
24namespace webrtc { class DtlsTransportInterface; }
25namespace webrtc { class IceCandidate; }
26namespace webrtc { class MediaStreamInterface; }
27namespace webrtc { class MediaStreamTrackInterface; }
28namespace webrtc { class NetworkControllerInterface; }
29namespace webrtc { class NetworkMask; }
30namespace webrtc { class RTCCertificate; }
31namespace webrtc { class RTCError; }
32namespace webrtc { class RTCStatsCollectorCallback; }
33namespace webrtc { class Resource; }
34namespace webrtc { class RtcEventLogOutput; }
35namespace webrtc { class RtpReceiverInterface; }
36namespace webrtc { class RtpSenderInterface; }
37namespace webrtc { class RtpTransceiverInterface; }
38namespace webrtc { class SctpTransportInterface; }
39namespace webrtc { class SessionDescriptionInterface; }
40namespace webrtc { class SetLocalDescriptionObserverInterface; }
41namespace webrtc { class SetRemoteDescriptionObserverInterface; }
42namespace webrtc { class SetSessionDescriptionObserver; }
43namespace webrtc { class StaticStunServer; }
44namespace webrtc { class StatsObserver; }
45namespace webrtc { class StreamCollectionInterface; }
46namespace webrtc { class Thread; }
47namespace webrtc { class TurnCustomizer; }
48namespace webrtc { struct BandwidthEstimationSettings; }
49namespace webrtc { struct BitrateSettings; }
50namespace webrtc { struct DataChannelInit; }
51namespace webrtc { struct RtpEncodingParameters; }
52namespace webrtc { struct RtpTransceiverInit; }
53// clang-format on
54
55namespace webrtc {
56
58public:
59 // PeerConnectionInterface inner types declare
60 // clang-format off
61 struct IceServer;
63 struct RTCConfiguration;
65 // clang-format on
66
67 // PeerConnectionInterface inner types define
68 enum class BundlePolicy : int {
69 KBundlePolicyBalanced = 0,
70 KBundlePolicyMaxBundle = 1,
71 KBundlePolicyMaxCompat = 2,
72 };
73
74 enum class CandidateNetworkPolicy : int {
75 KCandidateNetworkPolicyAll = 0,
76 KCandidateNetworkPolicyLowCost = 1,
77 };
78
79 enum class ContinualGatheringPolicy : int {
80 Once = 0,
81 Continually = 1,
82 };
83
84 enum class IceConnectionState : int {
85 KIceConnectionNew = 0,
86 KIceConnectionChecking = 1,
87 KIceConnectionConnected = 2,
88 KIceConnectionCompleted = 3,
89 KIceConnectionFailed = 4,
90 KIceConnectionDisconnected = 5,
91 KIceConnectionClosed = 6,
92 KIceConnectionMax = 7,
93 };
94
95 enum class IceGatheringState : int {
96 KIceGatheringNew = 0,
97 KIceGatheringGathering = 1,
98 KIceGatheringComplete = 2,
99 };
100
101 enum class IceTransportsType : int {
102 KNone = 0,
103 KRelay = 1,
104 KNoHost = 2,
105 KAll = 3,
106 };
107
108 enum class PeerConnectionState : int {
109 KNew = 0,
110 KConnecting = 1,
111 KConnected = 2,
112 KDisconnected = 3,
113 KFailed = 4,
114 KClosed = 5,
115 };
116
117 enum class RTCConfigurationType : int {
118 KSafe = 0,
119 KAggressive = 1,
120 };
121
122 enum class RtcpMuxPolicy : int {
123 KRtcpMuxPolicyNegotiate = 0,
124 KRtcpMuxPolicyRequire = 1,
125 };
126
127 enum class SignalingState : int {
128 KStable = 0,
129 KHaveLocalOffer = 1,
130 KHaveLocalPrAnswer = 2,
131 KHaveRemoteOffer = 3,
132 KHaveRemotePrAnswer = 4,
133 KClosed = 5,
134 };
135
136 enum class StatsOutputLevel : int {
137 KStatsOutputLevelStandard = 0,
138 KStatsOutputLevelDebug = 1,
139 };
140
141 enum class TcpCandidatePolicy : int {
142 KTcpCandidatePolicyEnabled = 0,
143 KTcpCandidatePolicyDisabled = 1,
144 };
145
146 enum class TlsCertPolicy : int {
147 KTlsCertPolicySecure = 0,
148 KTlsCertPolicyInsecureNoCheck = 1,
149 };
150
151 struct IceServer {
152 public:
153 // member variables
154 std::string uri;
155 std::vector<::std::string> urls;
156 std::string username;
157 std::string password;
158 webrtc::PeerConnectionInterface::TlsCertPolicy tls_cert_policy;
159 std::string hostname;
160 std::vector<::std::string> tls_alpn_protocols;
161 std::vector<::std::string> tls_elliptic_curves;
162 };
163
165 public:
166 // member variables
167 // NOLINTBEGIN
168 ::ll::TypedStorage<4, 4, int> min_port;
169 ::ll::TypedStorage<4, 4, int> max_port;
170 ::ll::TypedStorage<4, 4, uint> flags;
171 // NOLINTEND
172 };
173
175 public:
176 // member variables
177 // NOLINTBEGIN
178 ::ll::TypedStorage<8, 24, ::std::vector<::webrtc::PeerConnectionInterface::IceServer>> servers;
179 ::ll::TypedStorage<4, 4, ::webrtc::PeerConnectionInterface::IceTransportsType> type;
180 ::ll::TypedStorage<4, 4, ::webrtc::PeerConnectionInterface::BundlePolicy> bundle_policy;
181 ::ll::TypedStorage<4, 4, ::webrtc::PeerConnectionInterface::RtcpMuxPolicy> rtcp_mux_policy;
182 ::ll::TypedStorage<8, 24, ::std::vector<::webrtc::scoped_refptr<::webrtc::RTCCertificate>>> certificates;
183 ::ll::TypedStorage<4, 4, int> ice_candidate_pool_size;
184 ::ll::TypedStorage<1, 1, bool> disable_ipv6_on_wifi;
185 ::ll::TypedStorage<4, 4, int> max_ipv6_networks;
186 ::ll::TypedStorage<1, 1, bool> disable_link_local_networks;
187 ::ll::TypedStorage<4, 8, ::std::optional<int>> screencast_min_bitrate;
188 ::ll::TypedStorage<4, 4, ::webrtc::PeerConnectionInterface::TcpCandidatePolicy> tcp_candidate_policy;
189 ::ll::TypedStorage<4, 4, ::webrtc::PeerConnectionInterface::CandidateNetworkPolicy> candidate_network_policy;
190 ::ll::TypedStorage<4, 4, int> audio_jitter_buffer_max_packets;
191 ::ll::TypedStorage<1, 1, bool> audio_jitter_buffer_fast_accelerate;
192 ::ll::TypedStorage<4, 4, int> audio_jitter_buffer_min_delay_ms;
193 ::ll::TypedStorage<4, 4, int> ice_connection_receiving_timeout;
194 ::ll::TypedStorage<4, 4, int> ice_backup_candidate_pair_ping_interval;
195 ::ll::TypedStorage<4, 4, ::webrtc::PeerConnectionInterface::ContinualGatheringPolicy>
196 continual_gathering_policy;
197 ::ll::TypedStorage<1, 1, bool> prioritize_most_likely_ice_candidate_pairs;
198 ::ll::TypedStorage<4, 24, ::webrtc::MediaConfig> media_config;
199 ::ll::TypedStorage<1, 1, bool> prune_turn_ports;
200 ::ll::TypedStorage<4, 4, ::webrtc::PortPrunePolicy> turn_port_prune_policy;
201 ::ll::TypedStorage<1, 1, bool> presume_writable_when_fully_relayed;
202 ::ll::TypedStorage<1, 1, bool> enable_ice_renomination;
203 ::ll::TypedStorage<1, 1, bool> redetermine_role_on_ice_restart;
204 ::ll::TypedStorage<1, 1, bool> surface_ice_candidates_on_ice_transport_type_changed;
205 ::ll::TypedStorage<4, 8, ::std::optional<int>> ice_check_interval_strong_connectivity;
206 ::ll::TypedStorage<4, 8, ::std::optional<int>> ice_check_interval_weak_connectivity;
207 ::ll::TypedStorage<4, 8, ::std::optional<int>> ice_check_min_interval;
208 ::ll::TypedStorage<4, 8, ::std::optional<int>> ice_unwritable_timeout;
209 ::ll::TypedStorage<4, 8, ::std::optional<int>> ice_unwritable_min_checks;
210 ::ll::TypedStorage<4, 8, ::std::optional<int>> ice_inactive_timeout;
211 ::ll::TypedStorage<4, 8, ::std::optional<int>> stun_candidate_keepalive_interval;
212 ::ll::TypedStorage<8, 8, ::webrtc::TurnCustomizer*> turn_customizer;
213 ::ll::TypedStorage<4, 8, ::std::optional<::webrtc::AdapterType>> network_preference;
214 ::ll::TypedStorage<4, 4, ::webrtc::SdpSemantics> sdp_semantics;
215 ::ll::TypedStorage<1, 1, bool> active_reset_srtp_params;
216 ::ll::TypedStorage<8, 32, ::webrtc::CryptoOptions> crypto_options;
217 ::ll::TypedStorage<1, 1, bool> offer_extmap_allow_mixed;
218 ::ll::TypedStorage<8, 32, ::std::string> turn_logging_id;
219 ::ll::TypedStorage<1, 1, bool> enable_implicit_rollback;
220 ::ll::TypedStorage<4, 8, ::std::optional<int>> report_usage_pattern_delay_ms;
221 ::ll::TypedStorage<4, 8, ::std::optional<int>> stable_writable_connection_ping_interval_ms;
222 ::ll::TypedStorage<4, 4, ::webrtc::VpnPreference> vpn_preference;
223 ::ll::TypedStorage<8, 24, ::std::vector<::webrtc::NetworkMask>> vpn_list;
224 ::ll::TypedStorage<4, 12, ::webrtc::PeerConnectionInterface::PortAllocatorConfig> port_allocator_config;
225 ::ll::TypedStorage<8, 16, ::std::optional<::webrtc::TimeDelta>> pacer_burst_interval;
226 ::ll::TypedStorage<8, 24, ::std::vector<::std::shared_ptr<::webrtc::StaticStunServer const>>>
227 static_stun_servers;
228 // NOLINTEND
229
230 public:
231 // member functions
232 // NOLINTBEGIN
234
236
237 MCNAPI ::webrtc::PeerConnectionInterface::RTCConfiguration&
239
241
243 // NOLINTEND
244
245 public:
246 // constructor thunks
247 // NOLINTBEGIN
248 MCNAPI void* $ctor();
249
251 // NOLINTEND
252
253 public:
254 // destructor thunk
255 // NOLINTBEGIN
256 MCNAPI void $dtor();
257 // NOLINTEND
258 };
259
261 public:
262 // member variables
263 // NOLINTBEGIN
264 ::ll::TypedStorage<4, 4, int> offer_to_receive_video;
265 ::ll::TypedStorage<4, 4, int> offer_to_receive_audio;
266 ::ll::TypedStorage<1, 1, bool> voice_activity_detection;
267 ::ll::TypedStorage<1, 1, bool> ice_restart;
268 ::ll::TypedStorage<1, 1, bool> use_rtp_mux;
269 ::ll::TypedStorage<1, 1, bool> raw_packetization_for_video;
270 ::ll::TypedStorage<4, 4, int> num_simulcast_layers;
271 ::ll::TypedStorage<1, 1, bool> use_obsolete_sctp_sdp;
272 // NOLINTEND
273 };
274
275 using IceServers = ::std::vector<::webrtc::PeerConnectionInterface::IceServer>;
276
277public:
278 // virtual functions
279 // NOLINTBEGIN
280 virtual ::webrtc::scoped_refptr<::webrtc::StreamCollectionInterface> local_streams() = 0;
281
282 virtual ::webrtc::scoped_refptr<::webrtc::StreamCollectionInterface> remote_streams() = 0;
283
284 virtual bool AddStream(::webrtc::MediaStreamInterface* a1) = 0;
285
286 virtual void RemoveStream(::webrtc::MediaStreamInterface* a1) = 0;
287
288 virtual ::webrtc::RTCErrorOr<::webrtc::scoped_refptr<::webrtc::RtpSenderInterface>> AddTrack(
290 ::std::vector<::std::string> const& a2
291 ) = 0;
292
293 virtual ::webrtc::RTCErrorOr<::webrtc::scoped_refptr<::webrtc::RtpSenderInterface>> AddTrack(
295 ::std::vector<::std::string> const& a2,
296 ::std::vector<::webrtc::RtpEncodingParameters> const& a3
297 ) = 0;
298
299 virtual ::webrtc::RTCError RemoveTrackOrError(::webrtc::scoped_refptr<::webrtc::RtpSenderInterface> a1);
300
301 virtual ::webrtc::RTCErrorOr<::webrtc::scoped_refptr<::webrtc::RtpTransceiverInterface>>
303
304 virtual ::webrtc::RTCErrorOr<::webrtc::scoped_refptr<::webrtc::RtpTransceiverInterface>> AddTransceiver(
307 ) = 0;
308
309 virtual ::webrtc::RTCErrorOr<::webrtc::scoped_refptr<::webrtc::RtpTransceiverInterface>>
310 AddTransceiver(::webrtc::MediaType a1) = 0;
311
312 virtual ::webrtc::RTCErrorOr<::webrtc::scoped_refptr<::webrtc::RtpTransceiverInterface>>
313 AddTransceiver(::webrtc::MediaType a1, ::webrtc::RtpTransceiverInit const& a2) = 0;
314
315 virtual ::webrtc::scoped_refptr<::webrtc::RtpSenderInterface>
316 CreateSender(::std::string const& a1, ::std::string const& a2) = 0;
317
318 virtual ::std::vector<::webrtc::scoped_refptr<::webrtc::RtpSenderInterface>> GetSenders() const = 0;
319
320 virtual ::std::vector<::webrtc::scoped_refptr<::webrtc::RtpReceiverInterface>> GetReceivers() const = 0;
321
322 virtual ::std::vector<::webrtc::scoped_refptr<::webrtc::RtpTransceiverInterface>> GetTransceivers() const = 0;
323
324 virtual bool GetStats(
327 ::webrtc::PeerConnectionInterface::StatsOutputLevel a3
328 ) = 0;
329
330 virtual void GetStats(::webrtc::RTCStatsCollectorCallback* a1) = 0;
331
332 virtual void GetStats(
335 ) = 0;
336
337 virtual void GetStats(
340 ) = 0;
341
342 virtual void ClearStatsCache();
343
344 virtual ::webrtc::RTCErrorOr<::webrtc::scoped_refptr<::webrtc::DataChannelInterface>>
345 CreateDataChannelOrError(::std::string const& a1, ::webrtc::DataChannelInit const* a2);
346
347 virtual ::webrtc::scoped_refptr<::webrtc::DataChannelInterface>
348 CreateDataChannel(::std::string const& label, ::webrtc::DataChannelInit const* config);
349
350 virtual ::webrtc::SessionDescriptionInterface const* local_description() const = 0;
351
352 virtual ::webrtc::SessionDescriptionInterface const* remote_description() const = 0;
353
354 virtual ::webrtc::SessionDescriptionInterface const* current_local_description() const = 0;
355
356 virtual ::webrtc::SessionDescriptionInterface const* current_remote_description() const = 0;
357
358 virtual ::webrtc::SessionDescriptionInterface const* pending_local_description() const = 0;
359
360 virtual ::webrtc::SessionDescriptionInterface const* pending_remote_description() const = 0;
361
362 virtual void RestartIce() = 0;
363
364 virtual void CreateOffer(
367 ) = 0;
368
369 virtual void CreateAnswer(
372 ) = 0;
373
374 virtual void SetLocalDescription(
375 ::std::unique_ptr<::webrtc::SessionDescriptionInterface> a1,
377 );
378
380
381 virtual void
383
384 virtual void SetLocalDescription(::webrtc::SetSessionDescriptionObserver* a1);
385
386 virtual void SetRemoteDescription(
387 ::std::unique_ptr<::webrtc::SessionDescriptionInterface> a1,
389 ) = 0;
390
391 virtual void
393
394 virtual bool ShouldFireNegotiationNeededEvent(uint a1) = 0;
395
396 virtual ::webrtc::PeerConnectionInterface::RTCConfiguration GetConfiguration() = 0;
397
398 virtual ::webrtc::RTCError SetConfiguration(::webrtc::PeerConnectionInterface::RTCConfiguration const& a1) = 0;
399
400 virtual bool AddIceCandidate(::webrtc::IceCandidate const* a1) = 0;
401
402 virtual void
403 AddIceCandidate(::std::unique_ptr<::webrtc::IceCandidate> a1, ::std::function<void(::webrtc::RTCError)> a2);
404
405 virtual bool RemoveIceCandidate(::webrtc::IceCandidate const* a1) = 0;
406
407 virtual bool RemoveIceCandidates(::std::vector<::webrtc::Candidate> const& a1);
408
409 virtual ::webrtc::RTCError SetBitrate(::webrtc::BitrateSettings const& a1) = 0;
410
411 virtual void ReconfigureBandwidthEstimation(::webrtc::BandwidthEstimationSettings const& a1) = 0;
412
413 virtual void SetAudioPlayout(bool a1) = 0;
414
415 virtual void SetAudioRecording(bool a1) = 0;
416
417 virtual ::webrtc::scoped_refptr<::webrtc::DtlsTransportInterface>
418 LookupDtlsTransportByMid(::std::string const& a1) = 0;
419
420 virtual ::webrtc::scoped_refptr<::webrtc::SctpTransportInterface> GetSctpTransport() const = 0;
421
422 virtual ::webrtc::PeerConnectionInterface::SignalingState signaling_state() = 0;
423
424 virtual ::webrtc::PeerConnectionInterface::IceConnectionState ice_connection_state() = 0;
425
426 virtual ::webrtc::PeerConnectionInterface::IceConnectionState standardized_ice_connection_state() = 0;
427
428 virtual ::webrtc::PeerConnectionInterface::PeerConnectionState peer_connection_state() = 0;
429
430 virtual ::webrtc::PeerConnectionInterface::IceGatheringState ice_gathering_state() = 0;
431
432 virtual ::std::optional<bool> can_trickle_ice_candidates() = 0;
433
434 virtual void AddAdaptationResource(::webrtc::scoped_refptr<::webrtc::Resource> a1) = 0;
435
436 virtual bool StartRtcEventLog(::std::unique_ptr<::webrtc::RtcEventLogOutput> a1, int64 a2) = 0;
437
438 virtual bool StartRtcEventLog(::std::unique_ptr<::webrtc::RtcEventLogOutput> a1) = 0;
439
440 virtual void StopRtcEventLog() = 0;
441
442 virtual void SetDataChannelEventObserver(::std::unique_ptr<::webrtc::DataChannelEventObserverInterface> a1) = 0;
443
444 virtual void Close() = 0;
445
446 virtual ::webrtc::Thread* signaling_thread() const = 0;
447
448 virtual ::webrtc::NetworkControllerInterface* GetNetworkController() = 0;
449
450 virtual ~PeerConnectionInterface() /*override*/ = default;
451 // NOLINTEND
452
453public:
454 // static functions
455 // NOLINTBEGIN
456 MCNAPI static ::std::string_view AsString(::webrtc::PeerConnectionInterface::SignalingState state);
457 // NOLINTEND
458
459public:
460 // virtual function thunks
461 // NOLINTBEGIN
462 MCNAPI ::webrtc::scoped_refptr<::webrtc::DataChannelInterface>
463 $CreateDataChannel(::std::string const& label, ::webrtc::DataChannelInit const* config);
464
465
466 // NOLINTEND
467};
468
469} // namespace webrtc
Definition Candidate.h:12
Definition CreateSessionDescriptionObserver.h:16
Definition DataChannelEventObserverInterface.h:7
Definition DataChannelInterface.h:19
Definition DtlsTransportInterface.h:18
Definition IceCandidate.h:12
Definition MediaStreamInterface.h:18
Definition MediaStreamTrackInterface.h:11
Definition NetworkControllerInterface.h:24
Definition NetworkMask.h:7
Definition PeerConnectionInterface.h:57
MCAPI ::webrtc::scoped_refptr<::webrtc::DataChannelInterface > $CreateDataChannel(::std::string const &label, ::webrtc::DataChannelInit const *config)
static MCAPI ::std::string_view AsString(::webrtc::PeerConnectionInterface::SignalingState state)
Definition RTCCertificate.h:18
Definition RTCError.h:10
Definition RTCStatsCollectorCallback.h:16
Definition RefCountInterface.h:10
Definition Resource.h:15
Definition RtcEventLogOutput.h:7
Definition RtpReceiverInterface.h:25
Definition RtpSenderInterface.h:28
Definition RtpTransceiverInterface.h:23
Definition SctpTransportInterface.h:18
Definition SessionDescriptionInterface.h:17
Definition SetLocalDescriptionObserverInterface.h:15
Definition SetRemoteDescriptionObserverInterface.h:15
Definition SetSessionDescriptionObserver.h:15
Definition StaticStunServer.h:12
Definition StatsObserver.h:15
Definition StreamCollectionInterface.h:16
Definition Thread.h:20
Definition TurnCustomizer.h:13
Definition scoped_refptr.h:8
Definition BandwidthEstimationSettings.h:7
Definition BitrateSettings.h:7
Definition DataChannelInit.h:7
Definition PeerConnectionInterface.h:151
Definition PeerConnectionInterface.h:164
Definition PeerConnectionInterface.h:174
MCAPI::webrtc::PeerConnectionInterface::RTCConfiguration & operator=(::webrtc::PeerConnectionInterface::RTCConfiguration const &)
MCAPI bool operator==(::webrtc::PeerConnectionInterface::RTCConfiguration const &o) const
MCAPI void * $ctor(::webrtc::PeerConnectionInterface::RTCConfiguration const &)
MCAPI RTCConfiguration(::webrtc::PeerConnectionInterface::RTCConfiguration const &)
Definition PeerConnectionInterface.h:260
Definition RtpEncodingParameters.h:7
Definition RtpTransceiverInit.h:7