Skip to content
LeviMC
English
AutoLightDark
LeviLamina
Loading...
Searching...
No Matches
TCPInterface.h
1#pragma once
2
3#include "mc/_HeaderOutputPredefine.h"
4
5// auto generated forward declare list
6// clang-format off
7namespace RakNet { struct Packet; }
8namespace RakNet { struct SystemAddress; }
9// clang-format on
10
11namespace RakNet {
12
13class TCPInterface {
14public:
15 // TCPInterface inner types declare
16 // clang-format off
17 struct ThisPtrPlusSysAddr;
18 // clang-format on
19
20 // TCPInterface inner types define
21 struct ThisPtrPlusSysAddr {
22 public:
23 // member variables
24 // NOLINTBEGIN
30 // NOLINTEND
31
32 public:
33 // prevent constructor by default
34 ThisPtrPlusSysAddr& operator=(ThisPtrPlusSysAddr const&);
35 ThisPtrPlusSysAddr(ThisPtrPlusSysAddr const&);
36 ThisPtrPlusSysAddr();
37 };
38
39public:
40 // member variables
41 // NOLINTBEGIN
66 // NOLINTEND
67
68public:
69 // prevent constructor by default
70 TCPInterface& operator=(TCPInterface const&);
71 TCPInterface(TCPInterface const&);
72
73public:
74 // virtual functions
75 // NOLINTBEGIN
76 virtual ~TCPInterface() = default;
77
78 virtual void Send(char const* data, uint length, ::RakNet::SystemAddress const& systemAddress, bool broadcast);
79
80 virtual bool SendList(
81 char const** data,
82 uint const* lengths,
83 int const numParameters,
84 ::RakNet::SystemAddress const& systemAddress,
85 bool broadcast
86 );
87
88 virtual bool ReceiveHasPackets();
89
90 virtual ::RakNet::Packet* Receive();
91
92 virtual void PushBackPacket(::RakNet::Packet* packet, bool pushAtHead);
93 // NOLINTEND
94
95public:
96 // member functions
97 // NOLINTBEGIN
98 MCNAPI void CloseConnection(::RakNet::SystemAddress systemAddress);
99
100 MCNAPI ::RakNet::SystemAddress
101 Connect(char const* host, ushort remotePort, bool block, ushort socketFamily, char const* bindAddress);
102
103 MCNAPI bool
104 CreateListenSocket(ushort port, ushort maxIncomingConnections, ushort socketFamily, char const* bindAddress);
105
106 MCNAPI void DeallocatePacket(::RakNet::Packet* packet);
107
108 MCNAPI uint GetOutgoingDataBufferSize(::RakNet::SystemAddress systemAddress) const;
109
110 MCNAPI ::RakNet::SystemAddress HasCompletedConnectionAttempt();
111
112 MCNAPI ::RakNet::SystemAddress HasFailedConnectionAttempt();
113
114 MCNAPI ::RakNet::SystemAddress HasLostConnection();
115
116 MCNAPI uint64 SocketConnect(char const* host, ushort remotePort, ushort socketFamily, char const* bindAddress);
117
118 MCNAPI bool Start(
119 ushort port,
120 ushort maxIncomingConnections,
121 ushort maxConnections,
122 int _threadPriority,
123 ushort socketFamily,
124 char const* bindAddress
125 );
126
127 MCNAPI void Stop();
128
129 MCNAPI TCPInterface();
130 // NOLINTEND
131
132public:
133 // constructor thunks
134 // NOLINTBEGIN
135 MCNAPI void* $ctor();
136 // NOLINTEND
137
138public:
139 // virtual function thunks
140 // NOLINTBEGIN
141 MCNAPI void $Send(char const* data, uint length, ::RakNet::SystemAddress const& systemAddress, bool broadcast);
142
143 MCNAPI bool $SendList(
144 char const** data,
145 uint const* lengths,
146 int const numParameters,
147 ::RakNet::SystemAddress const& systemAddress,
148 bool broadcast
149 );
150
151 MCNAPI bool $ReceiveHasPackets();
152
153 MCNAPI ::RakNet::Packet* $Receive();
154
155 MCNAPI void $PushBackPacket(::RakNet::Packet* packet, bool pushAtHead);
156
157
158 // NOLINTEND
159};
160
161} // namespace RakNet
MCAPI void $Send(char const *data, uint length, ::RakNet::SystemAddress const &systemAddress, bool broadcast)
MCAPI void * $ctor()
MCAPI void CloseConnection(::RakNet::SystemAddress systemAddress)
MCAPI bool Start(ushort port, ushort maxIncomingConnections, ushort maxConnections, int _threadPriority, ushort socketFamily, char const *bindAddress)
MCAPI bool CreateListenSocket(ushort port, ushort maxIncomingConnections, ushort socketFamily, char const *bindAddress)
MCAPI void $PushBackPacket(::RakNet::Packet *packet, bool pushAtHead)
MCAPI void DeallocatePacket(::RakNet::Packet *packet)
MCAPI uint GetOutgoingDataBufferSize(::RakNet::SystemAddress systemAddress) const
MCAPI::RakNet::SystemAddress HasLostConnection()
MCAPI bool $ReceiveHasPackets()
MCAPI bool $SendList(char const **data, uint const *lengths, int const numParameters, ::RakNet::SystemAddress const &systemAddress, bool broadcast)
MCAPI::RakNet::SystemAddress HasCompletedConnectionAttempt()
MCAPI uint64 SocketConnect(char const *host, ushort remotePort, ushort socketFamily, char const *bindAddress)
MCAPI::RakNet::Packet * $Receive()
MCAPI::RakNet::SystemAddress Connect(char const *host, ushort remotePort, bool block, ushort socketFamily, char const *bindAddress)
MCAPI::RakNet::SystemAddress HasFailedConnectionAttempt()
Definition Packet.h:7
Definition SystemAddress.h:7
Definition TCPInterface.h:21
Definition Alias.h:14