LeviLamina
Loading...
Searching...
No Matches
LanThreadManager.h
1#pragma once
2
3#include "mc/_HeaderOutputPredefine.h"
4
5// auto generated inclusion list
6#include "mc/deps/nether_net/ContextProxy.h"
7#include "mc/deps/nether_net/Controller.h"
8#include "mc/external/rtc/Thread.h"
9#include "mc/external/sigslot/has_slots.h"
10#include "mc/external/sigslot/single_threaded.h"
11
12// auto generated forward declare list
13// clang-format off
14namespace NetherNet { struct DiscoveryResponsePacket; }
15namespace NetherNet { struct NetworkID; }
16namespace NetherNet { struct ThreadInit; }
17namespace rtc { class AsyncPacketSocket; }
18namespace rtc { class ReceivedPacket; }
19namespace rtc { class SocketAddress; }
20// clang-format on
21
22namespace NetherNet {
23
25 public ::rtc::Thread,
26 public ::sigslot::has_slots<::sigslot::single_threaded>,
28public:
29 // member variables
30 // NOLINTBEGIN
43 // NOLINTEND
44
45public:
46 // prevent constructor by default
47 LanThreadManager& operator=(LanThreadManager const&);
50
51public:
52 // virtual functions
53 // NOLINTBEGIN
54 // vIndex: 3
55 virtual ~LanThreadManager() /*override*/;
56 // NOLINTEND
57
58public:
59 // member functions
60 // NOLINTBEGIN
61 MCNAPI void BeginNetworkDiscovery();
62
63 MCNAPI void BroadcastTask();
64
66
67 MCNAPI void DestroyLanResources();
68
70
72
73 MCNAPI void Initialize(
74 char const* threadName,
75 ::NetherNet::ThreadInit const& threadInit,
76 uint64 applicationId,
77 ushort port,
78 ::std::chrono::milliseconds interval
79 );
80
82
84
86
88
89 MCNAPI void SendLanBroadcastRequest(::std::unique_ptr<::rtc::AsyncPacketSocket>& socket, ::NetherNet::NetworkID id);
90
92 ::rtc::SocketAddress const& destination,
94 );
95
97 ::NetherNet::NetworkID networkIdFrom,
98 ::NetherNet::NetworkID networkIdTo,
99 ::std::string const& message
100 );
101
103 ::std::unique_ptr<::rtc::AsyncPacketSocket>& socket,
104 ::NetherNet::NetworkID networkIdFrom,
105 ::NetherNet::NetworkID networkIdTo,
106 ::std::string const& message
107 );
108
109 MCNAPI ::std::error_code SendToHelper(
110 ::std::unique_ptr<::rtc::AsyncPacketSocket>& socket,
111 void const* data,
112 uint64 size,
113 ::rtc::SocketAddress const& addr
114 );
115
116 MCNAPI void Shutdown();
117 // NOLINTEND
118
119public:
120 // constructor thunks
121 // NOLINTBEGIN
122 MCNAPI void* $ctor(::NetherNet::ContextProxy const& ctx);
123 // NOLINTEND
124
125public:
126 // destructor thunk
127 // NOLINTBEGIN
128 MCNAPI void $dtor();
129 // NOLINTEND
130
131public:
132 // vftables
133 // NOLINTBEGIN
134 MCNAPI static void** $vftableForHasSlots();
135
136 MCNAPI static void** $vftableForThread();
137
138 MCNAPI static void** $vftableForContextProxy();
139 // NOLINTEND
140};
141
142} // namespace NetherNet
Definition ContextProxy.h:18
Definition LanThreadManager.h:27
MCAPI void * $ctor(::NetherNet::ContextProxy const &ctx)
MCAPI void SendLanBroadcastResponse(::rtc::SocketAddress const &destination, ::NetherNet::DiscoveryResponsePacket const &packet)
MCAPI void BeginNetworkDiscovery()
MCAPI void SendSignalingMessageTo(::NetherNet::NetworkID networkIdFrom, ::NetherNet::NetworkID networkIdTo, ::std::string const &message)
MCAPI void DestroyLanResources()
MCAPI void EnableBroadcastDiscovery(::NetherNet::NetworkID id)
MCAPI void OnNetworkDiscoveryComplete()
MCAPI bool IsBroadcastDiscoveryEnabled(::NetherNet::NetworkID id)
static MCAPI void ** $vftableForThread()
MCAPI void DisableBroadcastDiscovery(::NetherNet::NetworkID id)
static MCAPI void ** $vftableForContextProxy()
MCAPI void Initialize(char const *threadName, ::NetherNet::ThreadInit const &threadInit, uint64 applicationId, ushort port, ::std::chrono::milliseconds interval)
MCAPI void SendSignalingMessageTo(::std::unique_ptr<::rtc::AsyncPacketSocket > &socket, ::NetherNet::NetworkID networkIdFrom, ::NetherNet::NetworkID networkIdTo, ::std::string const &message)
MCAPI::std::error_code SendToHelper(::std::unique_ptr<::rtc::AsyncPacketSocket > &socket, void const *data, uint64 size, ::rtc::SocketAddress const &addr)
MCAPI LanThreadManager(::NetherNet::ContextProxy const &ctx)
MCAPI void OnPacket(::rtc::AsyncPacketSocket *, ::rtc::ReceivedPacket const &packet)
MCAPI void SendLanBroadcastRequest(::std::unique_ptr<::rtc::AsyncPacketSocket > &socket, ::NetherNet::NetworkID id)
static MCAPI void ** $vftableForHasSlots()
MCAPI void CreateEncryptedBroadcastSocket()
Definition Controller.h:7
Definition AsyncPacketSocket.h:20
Definition ReceivedPacket.h:16
Definition SocketAddress.h:12
Definition Thread.h:20
Definition has_slots.h:8
Definition DiscoveryResponsePacket.h:10
Definition NetworkID.h:12
Definition ThreadInit.h:7
Definition ctx.h:5
Definition Alias.h:14