mirror of
https://gitlab.ibr.cs.tu-bs.de/tschuber/ns-3-leo.git
synced 2025-06-09 02:23:57 +02:00
refactor stuff
This commit is contained in:
parent
57b04d6424
commit
97de8c9d24
15 changed files with 135 additions and 88 deletions
|
@ -3,6 +3,7 @@
|
|||
#include "ns3/core-module.h"
|
||||
#include "ns3/network-module.h"
|
||||
#include "ns3/internet-module.h"
|
||||
#include "ns3/log.h"
|
||||
#include "../model/leo-mock-net-device.h"
|
||||
|
||||
#include "nd-cache-helper.h"
|
||||
|
@ -10,9 +11,13 @@
|
|||
namespace ns3
|
||||
{
|
||||
|
||||
NS_LOG_COMPONENT_DEFINE ("NdCacheHelper");
|
||||
|
||||
void
|
||||
NdCacheHelper::Install (NetDeviceContainer &devices, Ipv6InterfaceContainer &interfaces) const
|
||||
{
|
||||
NS_LOG_FUNCTION (this);
|
||||
|
||||
// prepare NDS cache
|
||||
for (uint32_t i = 0; i < devices.GetN (); i++)
|
||||
{
|
||||
|
@ -47,6 +52,8 @@ NdCacheHelper::Install (NetDeviceContainer &devices, Ipv6InterfaceContainer &int
|
|||
entry = cache->Add (ipaddr);
|
||||
}
|
||||
entry->SetMacAddress (address);
|
||||
|
||||
NS_LOG_DEBUG ("Added entry for " << address);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue