3#include "mc/_HeaderOutputPredefine.h"
6#include "mc/deps/core/utility/NonOwnerPointer.h"
7#include "mc/network/StubServerLocator.h"
8#include "mc/platform/Result.h"
9#include "mc/platform/threading/UniqueLock.h"
10#include "mc/world/level/GameType.h"
22namespace Bedrock::Threading {
class Mutex; }
26class NetherNetServerLocator :
public ::StubServerLocator {
52 ServerData& operator=(ServerData
const&);
53 ServerData(ServerData
const&);
90 NetherNetServerLocator& operator=(NetherNetServerLocator
const&);
91 NetherNetServerLocator(NetherNetServerLocator
const&);
92 NetherNetServerLocator();
97 virtual ~NetherNetServerLocator() ;
99 virtual void startAnnouncingServer(
100 ::std::string
const& playerName,
101 ::std::string
const& worldName,
111 virtual void stopAnnouncingServer() ;
113 virtual void startServerDiscovery(
::PortPair) ;
115 virtual void stopServerDiscovery() ;
117 virtual ::std::vector<::PingedCompatibleServer> getServerList() const ;
119 virtual
void clearServerList() ;
121 virtual
void update() ;
127 MCNAPI NetherNetServerLocator(
129 ::Bedrock::NonOwnerPointer<::
AppPlatform> const& appPlatform,
135 MCNAPI
void _onDiscoveryResponse(::NetherNet::NetworkID const& networkID, ::gsl::span<
char const> responseData);
158 ::Bedrock::NonOwnerPointer<::
AppPlatform> const& appPlatform,
173 ::
std::
string const& playerName,
174 ::
std::
string const& worldName,
Definition BinaryStream.h:11
MCAPI void $stopAnnouncingServer()
MCAPI void _onDiscoveryResponse(::NetherNet::NetworkID const &networkID, ::gsl::span< char const > responseData)
MCAPI void _setIsDiscovering(bool isDiscovering)
static MCAPI void ** $vftable()
MCAPI void $clearServerList()
MCAPI void _setDiscoveryRequestCallback(bool enable)
static MCAPI ::PingedCompatibleServer _transformFrom(::NetherNet::NetworkID const &networkID, ::NetherNetServerLocator::ServerData &&serverData)
MCAPI void _cacheDiscoveryResponseData()
MCAPI void $stopServerDiscovery()
MCAPI void $startServerDiscovery(::PortPair)
MCAPI ::std::vector<::PingedCompatibleServer > $getServerList() const
MCAPI void * $ctor(::Bedrock::NotNullNonOwnerPtr<::NetherNetConnector > &&connector, ::Bedrock::NonOwnerPointer<::AppPlatform > const &appPlatform, ::Bedrock::NonOwnerPointer<::SignalingService > signalingService)
MCAPI void _setDiscoveryResponseCallback(bool enable)
MCAPI void $startAnnouncingServer(::std::string const &playerName, ::std::string const &worldName, ::GameType gameType, int numPlayers, int maxNumPlayers, bool isEditorWorld, bool isHardcore, bool supportedAuth, ::ServerSupportedAuthenticationTypes)
MCAPI void _pruneStaleServers(::std::chrono::seconds staleAfter)
Definition ReadOnlyBinaryStream.h:8
Definition SignalingService.h:41
Definition NetherNetConnector.h:33
Definition NetherNetServerLocator.h:34
MCAPI void write(::BinaryStream &stream) const
MCAPI::NetherNetServerLocator::ServerData & operator=(::NetherNetServerLocator::ServerData &&)
MCAPI ::Bedrock::Result< void > read(::ReadOnlyBinaryStream &stream)
Definition NetworkID.h:17
Definition PingedCompatibleServer.h:5
Definition ServerSupportedAuthenticationTypes.h:5