implement properly NetDevice::DoDispose and rename NetDevice::PeekNode to NetDevice::GetNode

This commit is contained in:
Mathieu Lacage
2007-05-10 08:18:41 +02:00
parent 96f4b45eab
commit e322d7f1df
4 changed files with 13 additions and 13 deletions

View File

@@ -39,13 +39,10 @@ NetDevice::NetDevice(Ptr<Node> node, const MacAddress& addr) :
m_isBroadcast (false),
m_isMulticast (false),
m_isPointToPoint (false)
{
}
{}
NetDevice::~NetDevice ()
{
m_node = 0;
}
{}
MacAddress
NetDevice::GetAddress (void) const
@@ -227,7 +224,7 @@ NetDevice::NotifyLinkDown (void)
}
Ptr<Node>
NetDevice::PeekNode (void) const
NetDevice::GetNode (void) const
{
return m_node;
}
@@ -246,6 +243,8 @@ NetDevice::SetReceiveCallback (Callback<bool,NetDevice *,const Packet &,uint16_t
void
NetDevice::DoDispose()
{}
{
m_node = 0;
}
}; // namespace ns3

View File

@@ -170,7 +170,7 @@ public:
* base class to print the nodeid for example, it can invoke
* this method.
*/
Ptr<Node> PeekNode (void) const;
Ptr<Node> GetNode (void) const;
bool NeedsArp (void) const;