Public Member Functions | Protected Attributes

IPv6ControlInfo Class Reference

#include <IPv6ControlInfo.h>

List of all members.

Public Member Functions

 IPv6ControlInfo ()
virtual ~IPv6ControlInfo ()
 IPv6ControlInfo (const IPv6ControlInfo &other)
IPv6ControlInfooperator= (const IPv6ControlInfo &other)
virtual void setOrigDatagram (IPv6Datagram *d)
virtual IPv6DatagramgetOrigDatagram () const
virtual IPv6DatagramremoveOrigDatagram ()

Protected Attributes

IPv6Datagramdgram

Detailed Description

Control information for sending/receiving packets over IPv6.

See the IPv6ControlInfo.msg file for more info.

Definition at line 30 of file IPv6ControlInfo.h.


Constructor & Destructor Documentation

IPv6ControlInfo::IPv6ControlInfo (  )  [inline]

Definition at line 35 of file IPv6ControlInfo.h.

: IPv6ControlInfo_Base() {dgram=NULL;}

IPv6ControlInfo::~IPv6ControlInfo (  )  [virtual]

Definition at line 21 of file IPv6ControlInfo.cc.

{
    if (dgram)
    {
        drop(dgram);
        delete dgram;
    }
}

IPv6ControlInfo::IPv6ControlInfo ( const IPv6ControlInfo other  )  [inline]

Definition at line 37 of file IPv6ControlInfo.h.

: IPv6ControlInfo_Base() {dgram=NULL; operator=(other);}


Member Function Documentation

virtual IPv6Datagram* IPv6ControlInfo::getOrigDatagram (  )  const [inline, virtual]

Definition at line 41 of file IPv6ControlInfo.h.

{return dgram;}

IPv6ControlInfo& IPv6ControlInfo::operator= ( const IPv6ControlInfo other  )  [inline]

Definition at line 38 of file IPv6ControlInfo.h.

{IPv6ControlInfo_Base::operator=(other); return *this;}

IPv6Datagram * IPv6ControlInfo::removeOrigDatagram (  )  [virtual]

Definition at line 38 of file IPv6ControlInfo.cc.

Referenced by ICMPv6::sendErrorMessage().

{
    if (!dgram)
        opp_error("IPv6ControlInfo::removeOrigDatagram(): no datagram attached "
                  "(already removed, or maybe this IPv6ControlInfo does not come "
                  "from the IPv6 module?)");
    IPv6Datagram *ret = dgram;
    drop(dgram);
    dgram = NULL;
    return ret;
}

void IPv6ControlInfo::setOrigDatagram ( IPv6Datagram d  )  [virtual]

Definition at line 30 of file IPv6ControlInfo.cc.

Referenced by IPv6::decapsulate().

{
    if (dgram)
        opp_error("IPv6ControlInfo::setOrigDatagram(): a datagram is already attached");
    dgram = d;
    take(dgram);
}


Member Data Documentation

Definition at line 33 of file IPv6ControlInfo.h.

Referenced by removeOrigDatagram(), setOrigDatagram(), and ~IPv6ControlInfo().


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