InterfaceTable

Package: inet.networklayer.common

InterfaceTable

simple module

Keeps the table of network interfaces.

Interfaces are dynamically registered by the corresponding L2 modules, e.g. PPPInterface. In addition to registered interfaces, a loopback interface will also be created. This table only contains protocol-independent properties of interfaces -- IPv4 or IPv6 specific per-interface data (addresses etc) are kept in IPv4RoutingTable and IPv6RoutingTable. Must be named as "interfaceTable".

This module has no gates; all functionality can be accessed via member functions of the C++ module class. For detailed info, please see the C++ documentation of the class (Doxygen).

Author:: Andras Varga

Used in compound modules

Name Type Description
AccessPoint compound module

A generic access point supporting multiple wireless radios, and multiple ethernet ports. The type of the ethernet MAC, relay unit and wireless card can be specified as parameters.

EtherSwitch compound module

Model of an Ethernet switch.

InternetCloud compound module

This module is an IPv4 router that can delay or drop packets (while retaining their order) based on which interface card the packet arrived on and on which interface it is leaving the cloud. The delayer module is replacable.

LDP_LSR compound module

An LDP-capable router.

NodeBase compound module

Contains the common lower layers (linklayer and networklayer) of Router, StandardHost, WirelessHost etc.

RSVP_LSR compound module

An RSVP-TE capable router.

Parameters

Name Type Default value Description
displayAddresses bool false

whether to display IP addresses on links

Properties

Name Value Description
display i=block/table

Signals

Name Type Unit
NF_IPv6_MCAST_JOIN inet::IPv6MulticastGroupInfo
NF_INTERFACE_STATE_CHANGED inet::InterfaceEntryChangeDetails
NF_IPv4_MCAST_REGISTERED inet::IPv4MulticastGroupInfo
NF_INTERFACE_IPv4CONFIG_CHANGED inet::InterfaceEntryChangeDetails
NF_IPv4_MCAST_CHANGE inet::IPv4MulticastGroupSourceInfo
NF_INTERFACE_IPv6CONFIG_CHANGED inet::InterfaceEntryChangeDetails
NF_INTERFACE_DELETED inet::InterfaceEntry
NF_IPv4_MCAST_LEAVE inet::IPv4MulticastGroupInfo
NF_INTERFACE_CONFIG_CHANGED inet::InterfaceEntryChangeDetails
NF_IPv4_MCAST_UNREGISTERED inet::IPv4MulticastGroupInfo
NF_IPv6_MCAST_LEAVE inet::IPv6MulticastGroupInfo
NF_IPv4_MCAST_JOIN inet::IPv4MulticastGroupInfo
NF_INTERFACE_CREATED inet::InterfaceEntry
NF_INTERFACE_GENERICNETWORKPROTOCOLCONFIG_CHANGED inet::InterfaceEntryChangeDetails

Source code

//
// Keeps the table of network interfaces.
//
// Interfaces are dynamically registered by the corresponding L2 modules, e.g.
// ~PPPInterface. In addition to registered interfaces, a loopback interface
// will also be created. This table only contains protocol-independent
// properties of interfaces -- IPv4 or IPv6 specific per-interface data
// (addresses etc) are kept in ~IPv4RoutingTable and ~IPv6RoutingTable.
// Must be named as "interfaceTable".
//
// This module has no gates; all functionality can be accessed via member
// functions of the C++ module class. For detailed info, please see the C++
// documentation of the class (Doxygen).
//
// @author: Andras Varga
//
simple InterfaceTable
{
    parameters:
        bool displayAddresses = default(false);  // whether to display IP addresses on links
        @display("i=block/table");
        @signal[NF_INTERFACE_CREATED](type=inet::InterfaceEntry);
        @signal[NF_INTERFACE_DELETED](type=inet::InterfaceEntry);
        @signal[NF_INTERFACE_STATE_CHANGED](type=inet::InterfaceEntryChangeDetails);
        @signal[NF_INTERFACE_CONFIG_CHANGED](type=inet::InterfaceEntryChangeDetails);
        @signal[NF_INTERFACE_IPv4CONFIG_CHANGED](type=inet::InterfaceEntryChangeDetails);
        @signal[NF_INTERFACE_IPv6CONFIG_CHANGED](type=inet::InterfaceEntryChangeDetails);
        @signal[NF_INTERFACE_GENERICNETWORKPROTOCOLCONFIG_CHANGED](type=inet::InterfaceEntryChangeDetails);
        @signal[NF_IPv4_MCAST_JOIN](type=inet::IPv4MulticastGroupInfo);
        @signal[NF_IPv4_MCAST_LEAVE](type=inet::IPv4MulticastGroupInfo);
        @signal[NF_IPv4_MCAST_CHANGE](type=inet::IPv4MulticastGroupSourceInfo);
        @signal[NF_IPv4_MCAST_REGISTERED](type=inet::IPv4MulticastGroupInfo);
        @signal[NF_IPv4_MCAST_UNREGISTERED](type=inet::IPv4MulticastGroupInfo);
        @signal[NF_IPv6_MCAST_JOIN](type=inet::IPv6MulticastGroupInfo);
        @signal[NF_IPv6_MCAST_LEAVE](type=inet::IPv6MulticastGroupInfo);
}

File: src/inet/networklayer/common/InterfaceTable.ned