MCPcopy Create free account
hub / github.com/OpenStarbound/OpenStarbound / UdpServer

Method UdpServer

source/core/StarUdp.cpp:56–61  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

54}
55
56UdpServer::UdpServer(HostAddressWithPort const& address)
57 : m_hostAddress(address), m_listenSocket(make_shared<UdpSocket>(m_hostAddress.address().mode())) {
58 m_listenSocket->setNonBlocking(true);
59 m_listenSocket->bind(m_hostAddress);
60 Logger::debug("UdpServer listening on: {}", m_hostAddress);
61}
62
63UdpServer::~UdpServer() {
64 close();

Callers

nothing calls this directly

Calls 4

addressMethod · 0.80
setNonBlockingMethod · 0.80
bindMethod · 0.80
modeMethod · 0.45

Tested by

no test coverage detected