17 : local_ip_address_{local_ip_address},
18 local_port_num_{port_num},
19 port_type_{port_type},
39 if (
udp_socket_->Transmit(std::move(udp_message)).HasValue()) { result.EmplaceValue(); }
PortType
Type of udp port to be used underneath.
Class type to contains a value (of type ValueType), or an error (of type ErrorType)
Class to manage a udp channel as per DoIP protocol.
void ProcessReceivedUdpUnicast(UdpMessagePtr udp_rx_message)
Function to process the received Udp unicast message from socket layer.
void ProcessReceivedUdpBroadcast(UdpMessagePtr udp_rx_message)
Function to process the received Udp broadcast message from socket layer.
UdpSocketHandler(std::string_view local_ip_address, std::uint16_t port_num, PortType port_type, DoipUdpChannel &channel)
Constructs an instance of UdpSocketHandler.
core_type::Result< void > Transmit(UdpMessageConstPtr udp_message)
Function to transmit the provided udp message.
boost_support::socket::udp::UdpMessagePtr UdpMessagePtr
Type alias for Udp message pointer.
std::uint16_t local_port_num_
Store the local port number.
boost_support::socket::udp::UdpMessageConstPtr UdpMessageConstPtr
Type alias for Udp message const pointer.
std::string local_ip_address_
Store the local ip address.
DoipUdpChannel & channel_
Store the reference to tcp channel.
std::unique_ptr< UdpSocket > udp_socket_
Store the socket object.
void Stop()
Function to stop the socket handler.
void Start()
Function to start the socket handler.
UdpSocket::PortType port_type_
Store the port type.
core_type::ErrorCode MakeErrorCode(DoipErrorErrc, core_type::ErrorDomain::SupportDataType data) noexcept
Create a new ErrorCode within DoipErrorDomain.