R-Type 0.1
Loading...
Searching...
No Matches
NetworkConfig.hpp
1#pragma once
2
8#include <cstddef>
9
11inline constexpr std::size_t MAX_PACKET_SIZE = 576;
13inline constexpr std::size_t IP_HEADER_SIZE = 20;
15inline constexpr std::size_t UDP_HEADER_SIZE = 8;
17inline constexpr std::size_t MAX_PAYLOAD_SIZE =
20inline constexpr std::size_t PACKET_HEADER_SIZE = 16;
22inline constexpr std::size_t MAX_MESSAGE_SIZE =
24
constexpr std::size_t MAX_MESSAGE_SIZE
Room left for messages after the packet header, in bytes.
Definition NetworkConfig.hpp:22
constexpr std::size_t PACKET_HEADER_SIZE
Size of the PacketHeader that starts every connected packet, in bytes.
Definition NetworkConfig.hpp:20
constexpr std::size_t MAX_PACKET_SIZE
Largest IPv4 datagram every host is required to accept, in bytes.
Definition NetworkConfig.hpp:11
constexpr std::size_t IP_HEADER_SIZE
Size of an IPv4 header without options, in bytes.
Definition NetworkConfig.hpp:13
constexpr std::size_t MAX_PAYLOAD_SIZE
Largest UDP payload sent or accepted by the network layer, in bytes.
Definition NetworkConfig.hpp:17
constexpr std::size_t UDP_HEADER_SIZE
Size of a UDP header, in bytes.
Definition NetworkConfig.hpp:15