8 #ifndef DIAG_CLIENT_LIB_LIB_BOOST_SUPPORT_INCLUDE_BOOST_SUPPORT_CLIENT_UDP_UDP_CLIENT_H_
9 #define DIAG_CLIENT_LIB_LIB_BOOST_SUPPORT_INCLUDE_BOOST_SUPPORT_CLIENT_UDP_UDP_CLIENT_H_
12 #include <string_view>
54 UdpClient(std::string_view local_ip_address, std::uint16_t local_port_num) noexcept;
Class to provide implementation of udp client.
Client that manages udp connection.
std::unique_ptr< UdpClientImpl > udp_client_impl_
Unique pointer to udp client implementation.
core_type::Result< void > Transmit(MessageConstPtr udp_message)
Function to transmit the provided tcp message.
void SetReadHandler(HandlerRead read_handler) noexcept
Function to set the read handler that is invoked when message is received.
boost_support::message::udp::UdpMessageConstPtr MessageConstPtr
Type alias for Tcp message const pointer.
void DeInitialize() noexcept
De-initialize the client.
UdpClient(std::string_view local_ip_address, std::uint16_t local_port_num) noexcept
Constructs an instance of UdpClient.
void Initialize() noexcept
Initialize the client.
UdpClient & operator=(UdpClient &&other) noexcept
std::function< void(MessagePtr)> HandlerRead
Tcp function template used for reception.
boost_support::message::udp::UdpMessagePtr MessagePtr
Type alias for Tcp message pointer.
UdpClient & operator=(const UdpClient &other) noexcept=delete
UdpClient(const UdpClient &other) noexcept=delete
Deleted copy assignment and copy constructor.
~UdpClient() noexcept
Destruct an instance of UdpClient.
UdpClient(UdpClient &&other) noexcept
Move assignment and move constructor.
Immutable class to store received udp message.
std::unique_ptr< UdpMessage > UdpMessagePtr
The unique pointer to UdpMessage.
std::unique_ptr< UdpMessage const > UdpMessageConstPtr
The unique pointer to const UdpMessage.
core_type::Result< T, E > Result
Class type to contains a value (of type ValueType), or an error (of type ErrorType)