acknowledge IPv4 and IPv6 as communication protocols for RLP
This commit is contained in:
parent
3f717454eb
commit
ab0c2f0e62
|
@ -32,9 +32,13 @@ namespace ACN::RLP {
|
|||
* @brief Component::Component
|
||||
* @param cid
|
||||
* @param fctn
|
||||
* @param ipv4
|
||||
* @param ipv6
|
||||
*/
|
||||
Component::Component(UUID::uuid cid, std::string fctn)
|
||||
Component::Component(UUID::uuid cid, std::string fctn, bool ipv4, bool ipv6)
|
||||
: ACN::Component(cid, fctn)
|
||||
, enable_IPv4(ipv4)
|
||||
, enable_IPv6(ipv6)
|
||||
{
|
||||
/// All RLP PDU generated by this component will referance the same header.
|
||||
rlp_header_ = std::make_shared<rlp_header>();
|
||||
|
|
|
@ -46,7 +46,22 @@ class Component
|
|||
: public ACN::Component
|
||||
{
|
||||
public:
|
||||
Component(UUID::uuid = UUID::uuid(), std::string fctn = "OpenLCP RLP Component");
|
||||
Component(UUID::uuid = UUID::uuid(), std::string fctn = "OpenLCP RLP Component",
|
||||
bool ipv4 = true, bool ipv6 = true);
|
||||
|
||||
/// \brief Set the IPv4 enabled state
|
||||
/// \param state
|
||||
virtual void setIPv4(const bool state) {enable_IPv4 = state;}
|
||||
/// \brief Read the IPv4 enabled state
|
||||
/// \return
|
||||
bool isEnabledIPv4() const {return enable_IPv4;}
|
||||
|
||||
/// \brief Set the IPv6 enabled state
|
||||
/// \param state
|
||||
virtual void setIPv6(const bool state) {enable_IPv6 = state;}
|
||||
/// \brief Read the IPv6 enabled state
|
||||
/// \return
|
||||
bool isEnabledIPv6() const {return enable_IPv6;}
|
||||
|
||||
// EPI 17 - ACN RLP on UDP
|
||||
virtual void UdpPayloadReceiver(PDU::Stream);
|
||||
|
@ -65,6 +80,9 @@ protected:
|
|||
virtual void sendUDP(const PDU::Stream, const SDT::UDP::ipAddress&);
|
||||
virtual void sendTCP(const PDU::Stream, const SDT::UDP::ipAddress&);
|
||||
|
||||
bool enable_IPv4; //!< enable rx/tx with IPv4
|
||||
bool enable_IPv6; //!< enable rx/tx with IPv6
|
||||
|
||||
private:
|
||||
std::map<uint32_t, std::vector<PDU::Handler<RLP::Pdu>>> rlp_vectors_;
|
||||
std::shared_ptr<rlp_header> rlp_header_;
|
||||
|
|
Loading…
Reference in New Issue