LeviLamina
Loading...
Searching...
No Matches
TCPPort.h
1#pragma once
2
3#include "mc/_HeaderOutputPredefine.h"
4
5// auto generated inclusion list
6#include "mc/external/cricket/Port.h"
7#include "mc/external/cricket/PortInterface.h"
8#include "mc/external/cricket/ProtocolType.h"
9#include "mc/external/rtc/Socket.h"
10
11// auto generated forward declare list
12// clang-format off
13namespace cricket { class Candidate; }
14namespace cricket { class Connection; }
15namespace rtc { class AsyncListenSocket; }
16namespace rtc { class AsyncPacketSocket; }
17namespace rtc { class Network; }
18namespace rtc { class PacketSocketFactory; }
19namespace rtc { class ReceivedPacket; }
20namespace rtc { class SocketAddress; }
21namespace rtc { class Thread; }
22namespace rtc { struct PacketOptions; }
23namespace rtc { struct SentPacket; }
24namespace webrtc { class FieldTrialsView; }
25// clang-format on
26
27namespace cricket {
28
29class TCPPort : public ::cricket::Port {
30public:
31 // TCPPort inner types declare
32 // clang-format off
33 struct Incoming;
34 // clang-format on
35
36 // TCPPort inner types define
37 struct Incoming {
38 public:
39 // member variables
40 // NOLINTBEGIN
43 // NOLINTEND
44
45 public:
46 // prevent constructor by default
47 Incoming& operator=(Incoming const&);
48 Incoming(Incoming const&);
49 Incoming();
50
51 public:
52 // member functions
53 // NOLINTBEGIN
54 MCNAPI ~Incoming();
55 // NOLINTEND
56
57 public:
58 // destructor thunk
59 // NOLINTBEGIN
60 MCNAPI void $dtor();
61 // NOLINTEND
62 };
63
64public:
65 // member variables
66 // NOLINTBEGIN
72 // NOLINTEND
73
74public:
75 // prevent constructor by default
76 TCPPort& operator=(TCPPort const&);
77 TCPPort(TCPPort const&);
78 TCPPort();
79
80public:
81 // virtual functions
82 // NOLINTBEGIN
83 // vIndex: 0
84 virtual ~TCPPort() /*override*/;
85
86 // vIndex: 11
87 virtual ::cricket::Connection* CreateConnection(
88 ::cricket::Candidate const& address,
89 ::cricket::PortInterface::CandidateOrigin origin
90 ) /*override*/;
91
92 // vIndex: 9
93 virtual void PrepareAddress() /*override*/;
94
95 // vIndex: 13
96 virtual int GetOption(::rtc::Socket::Option opt, int* value) /*override*/;
97
98 // vIndex: 12
99 virtual int SetOption(::rtc::Socket::Option opt, int value) /*override*/;
100
101 // vIndex: 14
102 virtual int GetError() /*override*/;
103
104 // vIndex: 8
105 virtual bool SupportsProtocol(::std::string_view protocol) const /*override*/;
106
107 // vIndex: 15
108 virtual ::cricket::ProtocolType GetProtocol() const /*override*/;
109
110 // vIndex: 17
111 virtual int SendTo(
112 void const* data,
113 uint64 size,
114 ::rtc::SocketAddress const& addr,
115 ::rtc::PacketOptions const& options,
116 bool payload
117 ) /*override*/;
118
119 // vIndex: 43
120 virtual void OnSentPacket(::rtc::AsyncPacketSocket* socket, ::rtc::SentPacket const& sent_packet) /*override*/;
121 // NOLINTEND
122
123public:
124 // member functions
125 // NOLINTBEGIN
126 MCNAPI ::rtc::AsyncPacketSocket* GetIncoming(::rtc::SocketAddress const& addr, bool remove);
127
128 MCNAPI void OnNewConnection(::rtc::AsyncListenSocket* socket, ::rtc::AsyncPacketSocket* new_socket);
129
130 MCNAPI void OnReadPacket(::rtc::AsyncPacketSocket* socket, ::rtc::ReceivedPacket const& packet);
131
132 MCNAPI void OnReadyToSend(::rtc::AsyncPacketSocket* socket);
133
134 MCNAPI TCPPort(
135 ::rtc::Thread* thread,
136 ::rtc::PacketSocketFactory* factory,
137 ::rtc::Network const* network,
138 ushort min_port,
139 ushort max_port,
140 ::std::string_view username,
141 ::std::string_view password,
142 bool allow_listen,
143 ::webrtc::FieldTrialsView const* field_trials
144 );
145
147 // NOLINTEND
148
149public:
150 // constructor thunks
151 // NOLINTBEGIN
152 MCNAPI void* $ctor(
153 ::rtc::Thread* thread,
154 ::rtc::PacketSocketFactory* factory,
155 ::rtc::Network const* network,
156 ushort min_port,
157 ushort max_port,
158 ::std::string_view username,
159 ::std::string_view password,
160 bool allow_listen,
161 ::webrtc::FieldTrialsView const* field_trials
162 );
163 // NOLINTEND
164
165public:
166 // destructor thunk
167 // NOLINTBEGIN
168 MCNAPI void $dtor();
169 // NOLINTEND
170
171public:
172 // virtual function thunks
173 // NOLINTBEGIN
174 MCNAPI ::cricket::Connection*
175 $CreateConnection(::cricket::Candidate const& address, ::cricket::PortInterface::CandidateOrigin origin);
176
177 MCNAPI void $PrepareAddress();
178
179 MCNAPI int $GetOption(::rtc::Socket::Option opt, int* value);
180
181 MCNAPI int $SetOption(::rtc::Socket::Option opt, int value);
182
183 MCNAPI int $GetError();
184
185 MCNAPI bool $SupportsProtocol(::std::string_view protocol) const;
186
187 MCNAPI ::cricket::ProtocolType $GetProtocol() const;
188
189 MCNAPI int $SendTo(
190 void const* data,
191 uint64 size,
192 ::rtc::SocketAddress const& addr,
193 ::rtc::PacketOptions const& options,
194 bool payload
195 );
196
197 MCNAPI void $OnSentPacket(::rtc::AsyncPacketSocket* socket, ::rtc::SentPacket const& sent_packet);
198 // NOLINTEND
199
200public:
201 // vftables
202 // NOLINTBEGIN
203 MCNAPI static void** $vftableForPortInterface();
204
205 MCNAPI static void** $vftableForHasSlots();
206 // NOLINTEND
207};
208
209} // namespace cricket
Definition Option.h:18
Definition Candidate.h:15
Definition Connection.h:38
Definition PortInterface.h:29
MCAPI void * $ctor()
Definition Port.h:36
MCAPI void OnReadyToSend()
Definition TCPPort.h:29
MCAPI::rtc::AsyncPacketSocket * GetIncoming(::rtc::SocketAddress const &addr, bool remove)
MCAPI void TryCreateServerSocket()
MCAPI bool $SupportsProtocol(::std::string_view protocol) const
static MCAPI void ** $vftableForHasSlots()
MCAPI void OnNewConnection(::rtc::AsyncListenSocket *socket, ::rtc::AsyncPacketSocket *new_socket)
MCAPI int $SendTo(void const *data, uint64 size, ::rtc::SocketAddress const &addr, ::rtc::PacketOptions const &options, bool payload)
MCAPI void OnReadPacket(::rtc::AsyncPacketSocket *socket, ::rtc::ReceivedPacket const &packet)
MCAPI::cricket::Connection * $CreateConnection(::cricket::Candidate const &address, ::cricket::PortInterface::CandidateOrigin origin)
MCAPI::cricket::ProtocolType $GetProtocol() const
MCAPI void $PrepareAddress()
MCAPI void $dtor()
MCAPI void $OnSentPacket(::rtc::AsyncPacketSocket *socket, ::rtc::SentPacket const &sent_packet)
MCAPI int $GetOption(::rtc::Socket::Option opt, int *value)
MCAPI int $GetError()
MCAPI int $SetOption(::rtc::Socket::Option opt, int value)
static MCAPI void ** $vftableForPortInterface()
STL namespace.
Definition TCPPort.h:37
Definition Alias.h:14