#include <TunInterface.h>
void inet::TunInterface::clearQueue |
( |
| ) |
|
|
overrideprotectedvirtual |
should create InterfaceEntry
Implements inet::MACBase.
40 InterfaceEntry *
e =
new InterfaceEntry(
this);
41 e->setMtu(par(
"mtu").longValue());
const value< double, units::C > e(1.602176487e-19)
void inet::TunInterface::finish |
( |
| ) |
|
|
overridevirtual |
void inet::TunInterface::flushQueue |
( |
| ) |
|
|
overrideprotectedvirtual |
should clear queue and emit signal "dropPkFromHLIfaceDown" with entire packets
Implements inet::MACBase.
void inet::TunInterface::handleMessage |
( |
cMessage * |
msg | ) |
|
|
overridevirtual |
47 if (msg->getArrivalGate()->isName(
"appIn")) {
49 send(msg,
"upperLayerOut");
51 else if (msg->getArrivalGate()->isName(
"upperLayerIn")) {
static simsignal_t packetSentToUpperSignal
Definition: TunInterface.h:36
static simsignal_t packetReceivedFromUpperSignal
Definition: TunInterface.h:37
void inet::TunInterface::initialize |
( |
int |
stage | ) |
|
|
overridevirtual |
Reimplemented from inet::MACBase.
virtual void initialize(int stage) override
Definition: MACBase.cc:37
Local initializations.
Definition: InitStages.h:35
void registerInterface()
Definition: MACBase.cc:98
virtual bool inet::TunInterface::isUpperMsg |
( |
cMessage * |
msg | ) |
|
|
inlineoverrideprotectedvirtual |
should return true if the msg arrived from upper layer, else return false
Implements inet::MACBase.
44 {
return msg->arrivedOn(
"upperLayerIn"); }
virtual int inet::TunInterface::numInitStages |
( |
| ) |
const |
|
inlineoverridevirtual |
Reimplemented from inet::MACBase.
The number of initialization stages.
Definition: InitStages.h:116
simsignal_t inet::TunInterface::packetReceivedFromLowerSignal = registerSignal("packetReceivedFromLower") |
|
staticprotected |
simsignal_t inet::TunInterface::packetReceivedFromUpperSignal = registerSignal("packetReceivedFromUpper") |
|
staticprotected |
simsignal_t inet::TunInterface::packetSentToLowerSignal = registerSignal("packetSentToLower") |
|
staticprotected |
simsignal_t inet::TunInterface::packetSentToUpperSignal = registerSignal("packetSentToUpper") |
|
staticprotected |
The documentation for this class was generated from the following files: