A network interface on which VRRP runs.
More...
#include <vrrp_interface.hh>
List of all members.
Public Member Functions |
| virtual bool | own (const IPv4 &addr)=0 |
| | Determines whether the router owns an IP address.
|
| virtual bool | ready () const =0 |
| | Check whether the network interface is up.
|
| virtual const IPv4 & | addr () const =0 |
| | Obtain the primary IP address of the interface.
|
| virtual void | send (const Mac &src, const Mac &dst, uint32_t ether, const PAYLOAD &payload)=0 |
| | Transmits a L2 packet.
|
|
virtual void | join_mcast ()=0 |
| | Join the VRRP multicast group on this interface.
|
|
virtual void | leave_mcast ()=0 |
| | Leave the VRRP multicast group on this interface.
|
| virtual void | add_mac (const Mac &mac)=0 |
| | Add a MAC address to this interface.
|
|
virtual void | add_ip (const IPv4 &ip)=0 |
| virtual void | delete_mac (const Mac &mac)=0 |
| | Delete a MAC address from this interface.
|
|
virtual void | delete_ip (const IPv4 &ip)=0 |
|
virtual void | start_arps ()=0 |
| | Start the reception of ARP packets.
|
|
virtual void | stop_arps ()=0 |
| | Stop the reception of ARP packets.
|
Detailed Description
A network interface on which VRRP runs.
This interface provides the means via which VRRP receives and send packets.
Member Function Documentation
| virtual void VrrpInterface::add_mac |
( |
const Mac & |
mac | ) |
[pure virtual] |
Add a MAC address to this interface.
- Parameters:
-
| virtual const IPv4& VrrpInterface::addr |
( |
| ) |
const [pure virtual] |
Obtain the primary IP address of the interface.
This is the first one configured.
- Returns:
- the primary IP address of the interface. The first configured.
| virtual void VrrpInterface::delete_mac |
( |
const Mac & |
mac | ) |
[pure virtual] |
Delete a MAC address from this interface.
- Parameters:
-
| mac | MAC address to delete from this interface. |
| virtual bool VrrpInterface::own |
( |
const IPv4 & |
addr | ) |
[pure virtual] |
Determines whether the router owns an IP address.
If the router has this IP address configured as the real IP address of one of its interfaces, then it owns it, else it does not.
- Returns:
- whether the router owns the IP address.
- Parameters:
-
| addr | the IP address to check for. |
| virtual bool VrrpInterface::ready |
( |
| ) |
const [pure virtual] |
Check whether the network interface is up.
- Returns:
- whether the interface is up and ready.
| virtual void VrrpInterface::send |
( |
const Mac & |
src, |
|
|
const Mac & |
dst, |
|
|
uint32_t |
ether, |
|
|
const PAYLOAD & |
payload |
|
) |
| [pure virtual] |
Transmits a L2 packet.
- Parameters:
-
| src | the source MAC address. |
| dst | the destination MAC address. |
| ether | the ethernet type. |
| payload | the data following the MAC header. |
The documentation for this class was generated from the following file: