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

Class generated from inet/linklayer/ieee8021d/common/Ieee8021dBPDU.msg:30 by nedtool. More...

#include <Ieee8021dBPDU_m.h>

Inheritance diagram for inet::BPDU:

Public Member Functions

 BPDU (const char *name=nullptr, short kind=0)
 
 BPDU (const BPDU &other)
 
virtual ~BPDU ()
 
BPDUoperator= (const BPDU &other)
 
virtual BPDUdup () const override
 
virtual void parsimPack (omnetpp::cCommBuffer *b) const override
 
virtual void parsimUnpack (omnetpp::cCommBuffer *b) override
 
virtual unsigned int getProtocolIdentifier () const
 
virtual void setProtocolIdentifier (unsigned int protocolIdentifier)
 
virtual unsigned int getProtocolVersionIdentifier () const
 
virtual void setProtocolVersionIdentifier (unsigned int protocolVersionIdentifier)
 
virtual unsigned int getBpduType () const
 
virtual void setBpduType (unsigned int bpduType)
 
virtual bool getTcaFlag () const
 
virtual void setTcaFlag (bool tcaFlag)
 
virtual bool getTcFlag () const
 
virtual void setTcFlag (bool tcFlag)
 
virtual MACAddressgetRootAddress ()
 
virtual const MACAddressgetRootAddress () const
 
virtual void setRootAddress (const MACAddress &rootAddress)
 
virtual unsigned int getRootPriority () const
 
virtual void setRootPriority (unsigned int rootPriority)
 
virtual unsigned int getRootPathCost () const
 
virtual void setRootPathCost (unsigned int rootPathCost)
 
virtual MACAddressgetBridgeAddress ()
 
virtual const MACAddressgetBridgeAddress () const
 
virtual void setBridgeAddress (const MACAddress &bridgeAddress)
 
virtual unsigned int getBridgePriority () const
 
virtual void setBridgePriority (unsigned int bridgePriority)
 
virtual unsigned int getPortNum () const
 
virtual void setPortNum (unsigned int portNum)
 
virtual unsigned int getPortPriority () const
 
virtual void setPortPriority (unsigned int portPriority)
 
virtual ::omnetpp::simtime_t getMessageAge () const
 
virtual void setMessageAge (::omnetpp::simtime_t messageAge)
 
virtual ::omnetpp::simtime_t getMaxAge () const
 
virtual void setMaxAge (::omnetpp::simtime_t maxAge)
 
virtual ::omnetpp::simtime_t getHelloTime () const
 
virtual void setHelloTime (::omnetpp::simtime_t helloTime)
 
virtual ::omnetpp::simtime_t getForwardDelay () const
 
virtual void setForwardDelay (::omnetpp::simtime_t forwardDelay)
 

Protected Member Functions

bool operator== (const BPDU &)
 

Protected Attributes

unsigned int protocolIdentifier
 
unsigned int protocolVersionIdentifier
 
unsigned int bpduType
 
bool tcaFlag
 
bool tcFlag
 
MACAddress rootAddress
 
unsigned int rootPriority
 
unsigned int rootPathCost
 
MACAddress bridgeAddress
 
unsigned int bridgePriority
 
unsigned int portNum
 
unsigned int portPriority
 
::omnetpp::simtime_t messageAge
 
::omnetpp::simtime_t maxAge
 
::omnetpp::simtime_t helloTime
 
::omnetpp::simtime_t forwardDelay
 

Private Member Functions

void copy (const BPDU &other)
 

Detailed Description

Class generated from inet/linklayer/ieee8021d/common/Ieee8021dBPDU.msg:30 by nedtool.

//
// Represents a BPDU (Bridge PDU) used by the STP and RSTP protocols,
// as defined in the 802.1D-1998 specification.
//
packet BPDU
{
    byteLength = 35;
    unsigned int protocolIdentifier;          // 0 for STP, 1 for RSTP (TODO use them)
    unsigned int protocolVersionIdentifier;   // currently 0
    unsigned int bpduType;                    // 0 for Configuration BPDU, 1 for Topology Change Notification BPDU
    bool tcaFlag;                             // Topology Change Acknowledgment flag
    bool tcFlag;                              // Topology Change flag
    MACAddress rootAddress;                   // address of the tree root (first part of Root Identifier)
    unsigned int rootPriority;                // priority of the tree root (second part of Root Identifier)
    unsigned int rootPathCost;                // cost to the root
    MACAddress bridgeAddress;                 // address of sender bridge (first part of Bridge Identifier)
    unsigned int bridgePriority;              // priority of sender bridge (second part of Bridge Identifier)
    unsigned int portNum;                     // port number (ethg[] gate index) of sender port (first part of Port Identifier)
    unsigned int portPriority;                // priority of sender port (second part of Port Identifier)
    simtime_t messageAge;                     // Message Age in seconds
    simtime_t maxAge;                         // maximum lifetime of the BPDU (seconds)
    simtime_t helloTime;                      // Hello Time of the sender bridge
    simtime_t forwardDelay;                   // Forward Delay timer of the sender bridge
}

Constructor & Destructor Documentation

inet::BPDU::BPDU ( const char *  name = nullptr,
short  kind = 0 
)
inet::BPDU::BPDU ( const BPDU other)
virtual inet::BPDU::~BPDU ( )
virtual

Member Function Documentation

void inet::BPDU::copy ( const BPDU other)
private
virtual BPDU* inet::BPDU::dup ( ) const
inlineoverridevirtual
103 {return new BPDU(*this);}
BPDU(const char *name=nullptr, short kind=0)
virtual unsigned int inet::BPDU::getBpduType ( ) const
virtual
virtual const MACAddress& inet::BPDU::getBridgeAddress ( ) const
inlinevirtual

Referenced by getBridgeAddress().

126 {return const_cast<BPDU*>(this)->getBridgeAddress();}
virtual MACAddress & getBridgeAddress()
BPDU(const char *name=nullptr, short kind=0)
virtual ::omnetpp::simtime_t inet::BPDU::getForwardDelay ( ) const
virtual ::omnetpp::simtime_t inet::BPDU::getHelloTime ( ) const
virtual ::omnetpp::simtime_t inet::BPDU::getMaxAge ( ) const
virtual ::omnetpp::simtime_t inet::BPDU::getMessageAge ( ) const
virtual unsigned int inet::BPDU::getProtocolIdentifier ( ) const
virtual
virtual unsigned int inet::BPDU::getProtocolVersionIdentifier ( ) const
virtual
virtual const MACAddress& inet::BPDU::getRootAddress ( ) const
inlinevirtual

Referenced by getRootAddress().

119 {return const_cast<BPDU*>(this)->getRootAddress();}
virtual MACAddress & getRootAddress()
BPDU(const char *name=nullptr, short kind=0)
virtual bool inet::BPDU::getTcaFlag ( ) const
virtual

Referenced by inet::STP::handleBPDU().

virtual bool inet::BPDU::getTcFlag ( ) const
virtual
BPDU& inet::BPDU::operator= ( const BPDU other)
bool inet::BPDU::operator== ( const BPDU )
protected
virtual void inet::BPDU::parsimPack ( omnetpp::cCommBuffer *  b) const
overridevirtual

Referenced by inet::doParsimPacking().

virtual void inet::BPDU::parsimUnpack ( omnetpp::cCommBuffer *  b)
overridevirtual

Referenced by inet::doParsimUnpacking().

virtual void inet::BPDU::setBpduType ( unsigned int  bpduType)
virtual
virtual void inet::BPDU::setBridgeAddress ( const MACAddress bridgeAddress)
virtual
virtual void inet::BPDU::setBridgePriority ( unsigned int  bridgePriority)
virtual
virtual void inet::BPDU::setForwardDelay ( ::omnetpp::simtime_t  forwardDelay)
virtual
virtual void inet::BPDU::setHelloTime ( ::omnetpp::simtime_t  helloTime)
virtual
virtual void inet::BPDU::setMaxAge ( ::omnetpp::simtime_t  maxAge)
virtual
virtual void inet::BPDU::setMessageAge ( ::omnetpp::simtime_t  messageAge)
virtual
virtual void inet::BPDU::setPortNum ( unsigned int  portNum)
virtual
virtual void inet::BPDU::setPortPriority ( unsigned int  portPriority)
virtual

Referenced by inet::STP::generateBPDU().

virtual void inet::BPDU::setProtocolIdentifier ( unsigned int  protocolIdentifier)
virtual
virtual void inet::BPDU::setProtocolVersionIdentifier ( unsigned int  protocolVersionIdentifier)
virtual
virtual void inet::BPDU::setRootAddress ( const MACAddress rootAddress)
virtual
virtual void inet::BPDU::setRootPathCost ( unsigned int  rootPathCost)
virtual
virtual void inet::BPDU::setRootPriority ( unsigned int  rootPriority)
virtual
virtual void inet::BPDU::setTcaFlag ( bool  tcaFlag)
virtual
virtual void inet::BPDU::setTcFlag ( bool  tcFlag)
virtual

Member Data Documentation

unsigned int inet::BPDU::bpduType
protected
MACAddress inet::BPDU::bridgeAddress
protected
unsigned int inet::BPDU::bridgePriority
protected
::omnetpp::simtime_t inet::BPDU::forwardDelay
protected
::omnetpp::simtime_t inet::BPDU::helloTime
protected
::omnetpp::simtime_t inet::BPDU::maxAge
protected
::omnetpp::simtime_t inet::BPDU::messageAge
protected
unsigned int inet::BPDU::portNum
protected
unsigned int inet::BPDU::portPriority
protected
unsigned int inet::BPDU::protocolIdentifier
protected
unsigned int inet::BPDU::protocolVersionIdentifier
protected
MACAddress inet::BPDU::rootAddress
protected
unsigned int inet::BPDU::rootPathCost
protected
unsigned int inet::BPDU::rootPriority
protected
bool inet::BPDU::tcaFlag
protected
bool inet::BPDU::tcFlag
protected

The documentation for this class was generated from the following file: