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

Class generated from inet/networklayer/common/SimpleNetworkProtocolControlInfo.msg:31 by nedtool. More...

#include <SimpleNetworkProtocolControlInfo_m.h>

Inheritance diagram for inet::SimpleNetworkProtocolControlInfo_Base:
inet::SimpleNetworkProtocolControlInfo

Public Member Functions

virtual ~SimpleNetworkProtocolControlInfo_Base ()
 
virtual SimpleNetworkProtocolControlInfo_Basedup () const override
 
virtual void parsimPack (omnetpp::cCommBuffer *b) const override
 
virtual void parsimUnpack (omnetpp::cCommBuffer *b) override
 
virtual L3Address_getDestinationAddress ()
 
virtual const L3Address_getDestinationAddress () const
 
virtual void setDestinationAddress (const L3Address &destinationAddress)
 
virtual L3Address_getSourceAddress ()
 
virtual const L3Address_getSourceAddress () const
 
virtual void setSourceAddress (const L3Address &sourceAddress)
 
virtual int getInterfaceId () const
 
virtual void setInterfaceId (int interfaceId)
 
virtual short getProtocol () const
 
virtual void setProtocol (short protocol)
 
virtual short getHopLimit () const
 
virtual void setHopLimit (short hopLimit)
 

Protected Member Functions

bool operator== (const SimpleNetworkProtocolControlInfo_Base &)
 
 SimpleNetworkProtocolControlInfo_Base ()
 
 SimpleNetworkProtocolControlInfo_Base (const SimpleNetworkProtocolControlInfo_Base &other)
 
SimpleNetworkProtocolControlInfo_Baseoperator= (const SimpleNetworkProtocolControlInfo_Base &other)
 

Protected Attributes

L3Address destinationAddress
 
L3Address sourceAddress
 
int interfaceId
 
short protocol
 
short hopLimit
 

Private Member Functions

void copy (const SimpleNetworkProtocolControlInfo_Base &other)
 

Detailed Description

Class generated from inet/networklayer/common/SimpleNetworkProtocolControlInfo.msg:31 by nedtool.

//
// Network level control information for sending/receiving packets.
//
class SimpleNetworkProtocolControlInfo
{
    @customize(true);
    L3Address destinationAddress @getter(_getDestinationAddress);
    L3Address sourceAddress @getter(_getSourceAddress);
    int interfaceId = -1;
    short protocol;
    short hopLimit;
}

SimpleNetworkProtocolControlInfo_Base is only useful if it gets subclassed, and SimpleNetworkProtocolControlInfo is derived from it. The minimum code to be written for SimpleNetworkProtocolControlInfo is the following:

class INET_API SimpleNetworkProtocolControlInfo : public SimpleNetworkProtocolControlInfo_Base
{
  private:
    void copy(const SimpleNetworkProtocolControlInfo& other) { ... }
  public:
    SimpleNetworkProtocolControlInfo() : SimpleNetworkProtocolControlInfo_Base() {}
    SimpleNetworkProtocolControlInfo(const SimpleNetworkProtocolControlInfo& other) : SimpleNetworkProtocolControlInfo_Base(other) {copy(other);}
    SimpleNetworkProtocolControlInfo& operator=(const SimpleNetworkProtocolControlInfo& other) {if (this==&other) return *this; SimpleNetworkProtocolControlInfo_Base::operator=(other); copy(other); return *this;}
    virtual SimpleNetworkProtocolControlInfo *dup() const override {return new SimpleNetworkProtocolControlInfo(*this);}
    // ADD CODE HERE to redefine and implement pure virtual functions from SimpleNetworkProtocolControlInfo_Base
};

The following should go into a .cc (.cpp) file:

Register_Class(SimpleNetworkProtocolControlInfo)

Constructor & Destructor Documentation

inet::SimpleNetworkProtocolControlInfo_Base::SimpleNetworkProtocolControlInfo_Base ( )
protected
inet::SimpleNetworkProtocolControlInfo_Base::SimpleNetworkProtocolControlInfo_Base ( const SimpleNetworkProtocolControlInfo_Base other)
protected
virtual inet::SimpleNetworkProtocolControlInfo_Base::~SimpleNetworkProtocolControlInfo_Base ( )
virtual

Member Function Documentation

virtual L3Address& inet::SimpleNetworkProtocolControlInfo_Base::_getDestinationAddress ( )
virtual
virtual const L3Address& inet::SimpleNetworkProtocolControlInfo_Base::_getDestinationAddress ( ) const
inlinevirtual
virtual L3Address& inet::SimpleNetworkProtocolControlInfo_Base::_getSourceAddress ( )
virtual
virtual const L3Address& inet::SimpleNetworkProtocolControlInfo_Base::_getSourceAddress ( ) const
inlinevirtual
void inet::SimpleNetworkProtocolControlInfo_Base::copy ( const SimpleNetworkProtocolControlInfo_Base other)
private
virtual SimpleNetworkProtocolControlInfo_Base* inet::SimpleNetworkProtocolControlInfo_Base::dup ( ) const
inlineoverridevirtual

Reimplemented in inet::SimpleNetworkProtocolControlInfo.

101 {throw omnetpp::cRuntimeError("You forgot to manually add a dup() function to class SimpleNetworkProtocolControlInfo");}
virtual short inet::SimpleNetworkProtocolControlInfo_Base::getHopLimit ( ) const
virtual
virtual int inet::SimpleNetworkProtocolControlInfo_Base::getInterfaceId ( ) const
virtual
virtual short inet::SimpleNetworkProtocolControlInfo_Base::getProtocol ( ) const
virtual
SimpleNetworkProtocolControlInfo_Base& inet::SimpleNetworkProtocolControlInfo_Base::operator= ( const SimpleNetworkProtocolControlInfo_Base other)
protected
bool inet::SimpleNetworkProtocolControlInfo_Base::operator== ( const SimpleNetworkProtocolControlInfo_Base )
protected
virtual void inet::SimpleNetworkProtocolControlInfo_Base::parsimPack ( omnetpp::cCommBuffer *  b) const
overridevirtual
virtual void inet::SimpleNetworkProtocolControlInfo_Base::parsimUnpack ( omnetpp::cCommBuffer *  b)
overridevirtual
virtual void inet::SimpleNetworkProtocolControlInfo_Base::setDestinationAddress ( const L3Address destinationAddress)
virtual
virtual void inet::SimpleNetworkProtocolControlInfo_Base::setHopLimit ( short  hopLimit)
virtual
virtual void inet::SimpleNetworkProtocolControlInfo_Base::setInterfaceId ( int  interfaceId)
virtual
virtual void inet::SimpleNetworkProtocolControlInfo_Base::setProtocol ( short  protocol)
virtual
virtual void inet::SimpleNetworkProtocolControlInfo_Base::setSourceAddress ( const L3Address sourceAddress)
virtual

Member Data Documentation

L3Address inet::SimpleNetworkProtocolControlInfo_Base::destinationAddress
protected
short inet::SimpleNetworkProtocolControlInfo_Base::hopLimit
protected
int inet::SimpleNetworkProtocolControlInfo_Base::interfaceId
protected
short inet::SimpleNetworkProtocolControlInfo_Base::protocol
protected
L3Address inet::SimpleNetworkProtocolControlInfo_Base::sourceAddress
protected

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