HAN-FUN API  1.5.3
This project provides the common implementation of ULE Alliance's HAN-FUN application protocol.
HF::Interfaces::Proxy< _Interface, _Proxy > Struct Template Reference

Helper template class to allow interfaces implementation to be added as fields to other classes. More...

#include <interface.h>

+ Inheritance diagram for HF::Interfaces::Proxy< _Interface, _Proxy >:
+ Collaboration diagram for HF::Interfaces::Proxy< _Interface, _Proxy >:

Public Member Functions

void send (const Protocol::Address &addr, Protocol::Message &message)
 Send message msg to the network address given by addr. More...
 
void notify (const HF::Attributes::IAttribute &old_value, const HF::Attributes::IAttribute &new_value) const
 Notify that an attribute value as changed. More...
 

Protected Attributes

_Proxy & proxy
 Referent to the class providing the required functionality.
 

Detailed Description

template<typename _Interface, typename _Proxy>
struct HF::Interfaces::Proxy< _Interface, _Proxy >

Helper template class to allow interfaces implementation to be added as fields to other classes.

Template Parameters
_Interfacebase parent interface class.
_Proxyclass providing the required methods for proper interface usage.

Definition at line 412 of file interface.h.

Member Function Documentation

◆ notify()

template<typename _Interface , typename _Proxy >
void HF::Interfaces::Proxy< _Interface, _Proxy >::notify ( const HF::Attributes::IAttribute old_value,
const HF::Attributes::IAttribute new_value 
) const
inline

Notify that an attribute value as changed.

Parameters
[in]old_valueattribute's old value.
[in]new_valueattribute's new value.

Definition at line 429 of file interface.h.

References HF::Interfaces::Proxy< _Interface, _Proxy >::proxy.

431  {
432  proxy.notify(old_value, new_value);
433  }
_Proxy & proxy
Referent to the class providing the required functionality.
Definition: interface.h:438

◆ send()

template<typename _Interface , typename _Proxy >
void HF::Interfaces::Proxy< _Interface, _Proxy >::send ( const Protocol::Address addr,
Protocol::Message message 
)
inline

Send message msg to the network address given by addr.

Parameters
[in]addrHF network address.
[in]messagepointer to the message to be sent to the network.

Definition at line 423 of file interface.h.

References HF::Interfaces::Proxy< _Interface, _Proxy >::proxy.

424  {
425  proxy.send(addr, message);
426  }
_Proxy & proxy
Referent to the class providing the required functionality.
Definition: interface.h:438

The documentation for this struct was generated from the following file: