20#ifndef FASTDDS_RTPS_TRANSPORT__TCPV4TRANSPORTDESCRIPTOR_HPP
21#define FASTDDS_RTPS_TRANSPORT__TCPV4TRANSPORTDESCRIPTOR_HPP
25#include <fastdds/rtps/transport/TCPTransportDescriptor.hpp>
26#include <fastdds/rtps/common/Types.hpp>
65 const std::string& in_address)
67 std::stringstream ss(in_address);
70 ss >> a >> ch >> b >> ch >> c >> ch >> d;
81 ss << static_cast<int>(
wan_addr[0]) <<
"."
82 <<
static_cast<int>(
wan_addr[1]) <<
"."
83 <<
static_cast<int>(
wan_addr[2]) <<
"."
Interface against which to implement a transport layer, decoupled from Fast DDS internals.
Definition TransportInterface.hpp:64
unsigned char octet
Definition Types.hpp:83
TCP Transport configuration.
Definition TCPTransportDescriptor.hpp:70
TCPv4 Transport configuration.
Definition TCPv4TransportDescriptor.hpp:41
FASTDDS_EXPORTED_API TCPv4TransportDescriptor(const TCPv4TransportDescriptor &t)
Copy constructor.
std::string get_WAN_address()
Get the public IP address.
Definition TCPv4TransportDescriptor.hpp:78
FASTDDS_EXPORTED_API TCPv4TransportDescriptor & operator=(const TCPv4TransportDescriptor &t)
Copy assignment.
FASTDDS_EXPORTED_API bool operator==(const TCPv4TransportDescriptor &t) const
Comparison operator.
fastdds::rtps::octet wan_addr[4]
Public IP address.
Definition TCPv4TransportDescriptor.hpp:48
FASTDDS_EXPORTED_API TCPv4TransportDescriptor()
Constructor.
void set_WAN_address(const std::string &in_address)
Set the public IP address.
Definition TCPv4TransportDescriptor.hpp:64
virtual ~TCPv4TransportDescriptor()=default
Destructor.
virtual TransportInterface * create_transport() const override
Factory method pattern.
void set_WAN_address(fastdds::rtps::octet o1, fastdds::rtps::octet o2, fastdds::rtps::octet o3, fastdds::rtps::octet o4)
Set the public IP address.
Definition TCPv4TransportDescriptor.hpp:51