|
INET Framework for OMNeT++/OMNEST
|
This class extends ProbabilisticBroadcast by adding an algorithm which adapts broadcasting parameters according to network conditions. More...
#include <AdaptiveProbabilisticBroadcast.h>
Public Member Functions | |
| AdaptiveProbabilisticBroadcast () | |
| virtual void | initialize (int) override |
| Initialization of the module and some variables. More... | |
Public Member Functions inherited from inet::ProbabilisticBroadcast | |
| ProbabilisticBroadcast () | |
| virtual int | numInitStages () const override |
| Initialization of the module and some variables. More... | |
| virtual void | finish () override |
| const Protocol & | getProtocol () const override |
Public Member Functions inherited from inet::NetworkProtocolBase | |
| virtual void | handleRegisterService (const Protocol &protocol, cGate *gate, ServicePrimitive servicePrimitive) override |
| virtual void | handleRegisterProtocol (const Protocol &protocol, cGate *gate, ServicePrimitive servicePrimitive) override |
Public Member Functions inherited from inet::OperationalMixin< cSimpleModule > | |
| virtual | ~OperationalMixin () |
| }@ More... | |
Public Member Functions inherited from inet::ILifecycle | |
| virtual | ~ILifecycle () |
Public Member Functions inherited from inet::DefaultProtocolRegistrationListener | |
| virtual void | handleRegisterServiceGroup (const ProtocolGroup &protocolGroup, cGate *gate, ServicePrimitive servicePrimitive) override |
| virtual void | handleRegisterProtocolGroup (const ProtocolGroup &protocolGroup, cGate *gate, ServicePrimitive servicePrimitive) override |
| virtual void | handleRegisterAnyService (cGate *gate, ServicePrimitive servicePrimitive) override |
| virtual void | handleRegisterAnyProtocol (cGate *gate, ServicePrimitive servicePrimitive) override |
Public Member Functions inherited from inet::INetworkProtocol | |
| virtual | ~INetworkProtocol () |
Protected Types | |
| typedef std::map< L3Address, cMessage * > | NeighborMap |
Protected Types inherited from inet::ProbabilisticBroadcast | |
| enum | messagesTypes { UNKNOWN = 0, BROADCAST_TIMER, NEIGHBOR_TIMER, BETA_TIMER } |
| typedef struct inet::ProbabilisticBroadcast::tMsgDesc | tMsgDesc |
| Store messages in a structure so that we can keep some information needed by the protocol. More... | |
| typedef std::set< unsigned int > | MsgIdSet |
| typedef std::multimap< simtime_t, tMsgDesc * > | TimeMsgMap |
Protected Types inherited from inet::OperationalMixin< cSimpleModule > | |
| enum | State |
Protected Member Functions | |
| virtual void | handleLowerPacket (Packet *packet) override |
| Handle messages from lower layer. More... | |
| virtual void | handleSelfMessage (cMessage *msg) override |
| Handle self messages. More... | |
| void | updateNeighMap (const ProbabilisticBroadcastHeader *m) |
| void | updateBeta () |
Protected Member Functions inherited from inet::ProbabilisticBroadcast | |
| virtual void | handleUpperPacket (Packet *packet) override |
| Handle messages from upper layer. More... | |
| virtual bool | messageKnown (unsigned int msgId) |
| Checks whether a message is known (= kept in memory) or not. More... | |
| virtual bool | debugMessageKnown (unsigned int msgId) |
| Checks whether a message is known (= kept in memory) or not. More... | |
| virtual void | insertMessage (simtime_t_cref bcastDelay, tMsgDesc *msgDesc) |
| Insert a message in both known ID list and message queue. More... | |
| virtual tMsgDesc * | popFirstMessageUpdateQueue (void) |
| Returns the descriptor of the first message in the queue, then remove its pointer from the queue and its id from the known IDs list. More... | |
| virtual void | encapsulate (Packet *packet) |
| Returns a network layer packet which encapsulates the upper layer packet passed to the function. More... | |
| virtual void | decapsulate (Packet *packet) |
| extracts and returns the application layer packet which is encapsulated in the network layer packet given in argument, delete network layer packet. More... | |
| virtual void | insertNewMessage (Packet *packet, bool iAmInitialSender=false) |
| Insert a new message in both known ID list and message queue. More... | |
| virtual void | setDownControlInfo (Packet *const pMsg, const MacAddress &pDestAddr) |
| Attaches a "control info" (NetwToMac) structure (object) to the message pMsg. More... | |
| virtual void | handleStartOperation (LifecycleOperation *operation) override |
| virtual void | handleStopOperation (LifecycleOperation *operation) override |
| virtual void | handleCrashOperation (LifecycleOperation *operation) override |
Protected Member Functions inherited from inet::NetworkProtocolBase | |
| NetworkProtocolBase () | |
| virtual | ~NetworkProtocolBase () |
| virtual void | sendUp (cMessage *message) |
| virtual void | sendDown (cMessage *message, int interfaceId=-1) |
| virtual bool | isUpperMessage (cMessage *message) const override |
| virtual bool | isLowerMessage (cMessage *message) const override |
| virtual bool | isInitializeStage (int stage) const override |
| virtual bool | isModuleStartStage (int stage) const override |
| virtual bool | isModuleStopStage (int stage) const override |
| virtual void | handleUpperCommand (cMessage *msg) override |
Protected Member Functions inherited from inet::LayeredProtocolBase | |
| virtual void | handleMessageWhenUp (cMessage *message) override |
| virtual void | handleUpperMessage (cMessage *message) |
| virtual void | handleLowerMessage (cMessage *message) |
| virtual void | handleLowerCommand (cMessage *message) |
Protected Member Functions inherited from inet::OperationalMixin< cSimpleModule > | |
| virtual int | numInitStages () const override |
| virtual void | refreshDisplay () const override |
| virtual void | handleMessage (cMessage *msg) override |
| virtual void | handleMessageWhenDown (cMessage *msg) |
| virtual bool | handleOperationStage (LifecycleOperation *operation, IDoneCallback *doneCallback) override |
| Perform one stage of a lifecycle operation. More... | |
| virtual State | getInitialOperationalState () const |
| Returns initial operational state: OPERATING or NOT_OPERATING. More... | |
| virtual void | handleActiveOperationTimeout (cMessage *message) |
| virtual bool | isUp () const |
| utility functions More... | |
| virtual bool | isDown () const |
| virtual void | setOperationalState (State newState) |
| virtual void | scheduleOperationTimeout (simtime_t timeout) |
| virtual void | setupActiveOperation (LifecycleOperation *operation, IDoneCallback *doneCallback, State) |
| virtual void | delayActiveOperationFinish (simtime_t timeout) |
| virtual void | startActiveOperationExtraTime (simtime_t delay=SIMTIME_ZERO) |
| virtual void | startActiveOperationExtraTimeOrFinish (simtime_t extraTime) |
| virtual void | finishActiveOperation () |
Protected Attributes | |
| simtime_t | timeInNeighboursTable |
| Default ttl for NeighborTable entries in seconds. More... | |
| cOutVector | bvec |
| NeighborMap | neighMap |
Protected Attributes inherited from inet::ProbabilisticBroadcast | |
| simtime_t | broadcastPeriod |
| Period (in sim time) between two broadcast attempts. More... | |
| double | beta = 0.0 |
| Probability of each broadcast attempt. More... | |
| simtime_t | timeToLive |
| int | maxNbBcast = 0 |
| Maximal number of broadcast attempts for each packet. More... | |
| simtime_t | maxFirstBcastBackoff |
| Maximal back-off before first broadcast attempt [seconds]. More... | |
| simtime_t | timeInQueueAfterDeath |
| How long the message should be kept in queue after its died. More... | |
| int | headerLength = 0 |
| Length of the NetwPkt header Read from omnetpp.ini. More... | |
| cMessage * | broadcastTimer = nullptr |
| MsgIdSet | knownMsgIds |
| TimeMsgMap | msgQueue |
| MsgIdSet | debugMsgIdSet |
| long | nbDataPacketsReceived = 0 |
| long | nbDataPacketsSent = 0 |
| long | nbHops = 0 |
| int | debugNbMessageKnown = 0 |
| long | nbDataPacketsForwarded = 0 |
| cOutVector | oneHopLatencies |
| L3Address | myNetwAddr |
Protected Attributes inherited from inet::NetworkProtocolBase | |
| ModuleRefByPar< IInterfaceTable > | interfaceTable |
| std::set< const Protocol * > | upperProtocols |
| std::map< int, SocketDescriptor * > | socketIdToSocketDescriptor |
Protected Attributes inherited from inet::OperationalMixin< cSimpleModule > | |
| State | operationalState |
| simtime_t | lastChange |
| Operation | activeOperation |
| cMessage * | activeOperationTimeout |
| cMessage * | activeOperationExtraTimer |
Additional Inherited Members | |
Static Protected Member Functions inherited from inet::ProbabilisticBroadcast | |
| static long | getNextID () |
Static Protected Attributes inherited from inet::ProbabilisticBroadcast | |
| static long | id_counter = 0 |
This class extends ProbabilisticBroadcast by adding an algorithm which adapts broadcasting parameters according to network conditions.
|
protected |
|
overrideprotectedvirtual |
|
overrideprotectedvirtual |
Handle self messages.
Reimplemented from inet::ProbabilisticBroadcast.
|
overridevirtual |
|
protected |
Referenced by handleSelfMessage(), and updateNeighMap().
|
protected |
Referenced by handleLowerPacket().
|
protected |
Referenced by initialize(), and updateBeta().
|
protected |
Referenced by handleSelfMessage(), updateBeta(), and updateNeighMap().
|
protected |
Default ttl for NeighborTable entries in seconds.
Referenced by initialize(), and updateNeighMap().