InternetCloud
Package: inet.node.internetcloud

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 replaceable.

By default the delayer module is MatrixCloudDelayer which lets you configure the delay, drop and datarate parameters in an XML file. Packet flows, as defined by incoming and outgoing interface pairs, are independent of each other.

The InternetCloud module can be used only to model the delay between two hops, but it is possible to build more complex networks using several InternetCloud modules.

See also: MatrixCloudDelayer

NodeStatus IEnergyStorage IEnergyManagement IEnergyGenerator IMobility PcapRecorder InterfaceTable ILoopbackInterface IWirelessInterface IPppInterface IEthernetInterface IExternalInterface ITunnelInterface INetworkLayer INetworkLayer INetworkLayer MessageDispatcher ICloudDelayer ICloudDelayer ICloudDelayer

Usage diagram

The following diagram shows usage relationships between types. Unresolved types are missing from the diagram.

Inheritance diagram

The following diagram shows inheritance relationships for this type. Unresolved types are missing from the diagram.

Extends

Name Type Description
NetworkLayerNodeBase compound module (no description)

Parameters

Name Type Default value Description
hasStatus bool false
osgModel string ""

3D model for OSG visualization, no 3D model by default

osgModelColor string ""

tint color, no colorization by default

canvasImage string ""

image for canvas visualization, no image by default

canvasImageColor string ""

tint color, no colorization by default

numPcapRecorders int 0
numLoInterfaces int 0
numWlanInterfaces int 0
numEthInterfaces int 0

minimum number of ethernet interfaces

numExtInterfaces int 0
numPppInterfaces int 0

minimum number of PPP interfaces

numTunInterfaces int 0
hasIpv4 bool true
hasIpv6 bool false
hasGn bool false
forwarding bool true
multicastForwarding bool false

Properties

Name Value Description
networkNode
labels node
display i=misc/cloud

Gates

Name Direction Size Description
radioIn [ ] input numWlanInterfaces
pppg [ ] inout numPppInterfaces
ethg [ ] inout numEthInterfaces

Unassigned submodule parameters

Name Type Default value Description
status.initialStatus string "UP"

TODO @signal, @statistic

pcapRecorder.verbose bool false

whether to log packets on the module output

pcapRecorder.pcapFile string ""

the PCAP file to be written

pcapRecorder.pcapNetwork int 0

the network type header field in the PCAP file, see http://www.tcpdump.org/linktypes.html (1=ethernet, 204=ppp, 105=IEEE 802.11, ...)

pcapRecorder.snaplen int 65535

maximum number of bytes to record per packet

pcapRecorder.dumpBadFrames bool true

enable dump of frames with hasBitError

pcapRecorder.moduleNamePatterns string "wlan[*] eth[*] ppp[*] ext[*]"

space-separated list of sibling module names to listen on

pcapRecorder.sendingSignalNames string "packetSentToLower"

space-separated list of outbound packet signals to subscribe to

pcapRecorder.receivingSignalNames string "packetReceivedFromLower"

space-separated list of inbound packet signals to subscribe to

pcapRecorder.dumpProtocols string "ethernetmac ppp ieee80211mac"

space-separated list of protocol names as defined in the Protocol class

pcapRecorder.packetFilter string "*"

which packets are considered, matches all packets by default

pcapRecorder.packetDataFilter string "*"

which packets are considered based on the data they contain, matches all packets by default

pcapRecorder.alwaysFlush bool false

flush the pcapFile after each write to ensure that all packets are captured in case of a crash

interfaceTable.displayAddresses bool false

whether to display IP addresses on links

Source code

//
// 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 replaceable.
//
// By default the delayer module is ~MatrixCloudDelayer which lets you configure
// the delay, drop and datarate parameters in an XML file. Packet flows, as defined
// by incoming and outgoing interface pairs, are independent of each other.
//
// The ~InternetCloud module can be used only to model the delay between two hops, but
// it is possible to build more complex networks using several ~InternetCloud modules.
//
// @see MatrixCloudDelayer
//
module InternetCloud extends NetworkLayerNodeBase
{
    parameters:
        numLoInterfaces = 0;
        numTunInterfaces = 0;
        forwarding = true;
        @display("i=misc/cloud");
        @figure[submodules];
        *.interfaceTableModule = default(absPath(".interfaceTable"));
    submodules:
        ipv4Delayer: <default("MatrixCloudDelayer")> like ICloudDelayer if hasIpv4 {
            parameters:
                networkProtocolModule = "^.ipv4.ip";
                @display("p=825,376");
        }
        ipv6Delayer: <default("MatrixCloudDelayer")> like ICloudDelayer if hasIpv6 {
            parameters:
                networkProtocolModule = "^.ipv6.ipv6";
                @display("p=975,376");
        }
        gnDelayer: <default("MatrixCloudDelayer")> like ICloudDelayer if hasGn {
            parameters:
                networkProtocolModule = "^.generic.nextHop";
                @display("p=1125,376");
        }
    connections allowunconnected:
}
File: src/inet/node/internetcloud/InternetCloud.ned