INET Framework for OMNeT++/OMNEST
inet::DsdvIpv4Route Class Reference

IPv4 route used by the DSDV protocol (DSDV module). More...

#include <Dsdv.h>

Inheritance diagram for inet::DsdvIpv4Route:
inet::Ipv4Route inet::IRoute

Public Member Functions

virtual bool isValid () const override
 test validity of route entry, e.g. More...
 
simtime_t getExpiryTime () const
 
void setExpiryTime (simtime_t time)
 
void setSequencenumber (int i)
 
unsigned int getSequencenumber () const
 
- Public Member Functions inherited from inet::Ipv4Route
 Ipv4Route ()
 
virtual ~Ipv4Route ()
 
virtual std::string str () const override
 
virtual std::string detailedInfo () const
 
bool operator== (const Ipv4Route &route) const
 
bool operator!= (const Ipv4Route &route) const
 
bool equals (const Ipv4Route &route) const
 
virtual void setRoutingTable (IIpv4RoutingTable *rt)
 To be called by the routing table when this route is added or removed from it. More...
 
IIpv4RoutingTablegetRoutingTable () const
 
virtual void setDestination (Ipv4Address _dest)
 
virtual void setNetmask (Ipv4Address _netmask)
 
virtual void setGateway (Ipv4Address _gateway)
 
virtual void setInterface (NetworkInterface *_interfacePtr) override
 
virtual void setSourceType (SourceType _source) override
 
const char * getSourceTypeAbbreviation () const
 
virtual void setAdminDist (unsigned int _adminDist) override
 
virtual void setMetric (int _metric) override
 
const Ipv4AddressgetDestination () const
 Destination address prefix to match. More...
 
const Ipv4AddressgetNetmask () const
 Represents length of prefix to match. More...
 
const Ipv4AddressgetGateway () const
 Next hop address. More...
 
NetworkInterfacegetInterface () const override
 Next hop interface. More...
 
const char * getInterfaceName () const
 Convenience method. More...
 
SourceType getSourceType () const override
 Source of route. More...
 
unsigned int getAdminDist () const
 Route source specific preference value. More...
 
int getMetric () const override
 "Cost" to reach the destination More...
 
void setSource (cObject *_source) override
 
cObject * getSource () const override
 Source of route. More...
 
cObject * getProtocolData () const override
 
void setProtocolData (cObject *protocolData) override
 
virtual IRoutingTablegetRoutingTableAsGeneric () const override
 The routing table in which this route is inserted, or nullptr. More...
 
virtual void setDestination (const L3Address &dest) override
 
virtual void setPrefixLength (int len) override
 
virtual void setNextHop (const L3Address &nextHop) override
 
virtual L3Address getDestinationAsGeneric () const override
 Destination address prefix to match. More...
 
virtual int getPrefixLength () const override
 Represents length of prefix to match. More...
 
virtual L3Address getNextHopAsGeneric () const override
 Next hop address. More...
 
- Public Member Functions inherited from inet::IRoute
virtual ~IRoute ()
 
virtual void setSourceType (SourceType type)=0
 

Protected Attributes

unsigned int sequencenumber
 
simtime_t expiryTime
 

Additional Inherited Members

- Public Types inherited from inet::IRoute
enum  SourceType {
  MANUAL, IFACENETMASK, ROUTER_ADVERTISEMENT, OWN_ADV_PREFIX,
  ICMP_REDIRECT, RIP, OSPF, BGP,
  ZEBRA, MANET, MANET2, DYMO,
  AODV, EIGRP, LISP, BABEL,
  ODR, UNKNOWN, ISIS
}
 Specifies where the route comes from. More...
 
enum  ChangeCodes {
  F_DESTINATION, F_PREFIX_LENGTH, F_NEXTHOP, F_IFACE,
  F_SOURCE, F_TYPE, F_ADMINDIST, F_METRIC,
  F_EXPIRYTIME, F_LAST
}
 Field codes for NB_ROUTE_CHANGED notifications. More...
 
enum  RouteAdminDist {
  dDirectlyConnected = 0, dStatic = 1, dEIGRPSummary = 5, dBGPExternal = 20,
  dEIGRPInternal = 90, dIGRP = 100, dOSPF = 110, dISIS = 115,
  dRIP = 120, dEGP = 140, dODR = 160, dEIGRPExternal = 170,
  dBGPInternal = 200, dDHCPlearned = 254, dBABEL = 125, dLISP = 210,
  dUnknown = 255
}
 Cisco like administrative distances. More...
 
- Static Public Member Functions inherited from inet::IRoute
static const char * sourceTypeName (SourceType sourceType)
 
- Protected Member Functions inherited from inet::Ipv4Route
void changed (int fieldCode)
 

Detailed Description

IPv4 route used by the DSDV protocol (DSDV module).

Member Function Documentation

◆ getExpiryTime()

simtime_t inet::DsdvIpv4Route::getExpiryTime ( ) const
inline
99 { return expiryTime; }

◆ getSequencenumber()

unsigned int inet::DsdvIpv4Route::getSequencenumber ( ) const
inline
102 { return sequencenumber; }

Referenced by inet::Dsdv::handleMessageWhenUp().

◆ isValid()

virtual bool inet::DsdvIpv4Route::isValid ( ) const
inlineoverridevirtual

test validity of route entry, e.g.

check expiry

Reimplemented from inet::Ipv4Route.

97 { return expiryTime == 0 || expiryTime > simTime(); }

◆ setExpiryTime()

void inet::DsdvIpv4Route::setExpiryTime ( simtime_t  time)
inline
100 { expiryTime = time; }

◆ setSequencenumber()

void inet::DsdvIpv4Route::setSequencenumber ( int  i)
inline
101 { sequencenumber = i; }

Member Data Documentation

◆ expiryTime

simtime_t inet::DsdvIpv4Route::expiryTime
protected

◆ sequencenumber

unsigned int inet::DsdvIpv4Route::sequencenumber
protected

The documentation for this class was generated from the following file:
inet::DsdvIpv4Route::expiryTime
simtime_t expiryTime
Definition: Dsdv.h:94
inet::DsdvIpv4Route::sequencenumber
unsigned int sequencenumber
Definition: Dsdv.h:93