bug 153
This commit is contained in:
1 parent
0d3872957b
commit
8d633f5fcd
5 files changed
+9
-9
No files matched your search
@@ -68,7 +68,7 @@ main (int argc, char *argv[])
|
||||
n0->AddDevice (net0);
|
||||
|
||||
Ptr<Queue> q = CreateObject<DropTailQueue> ();
|
||||
net0->AddQueue(q);
|
||||
net0->SetQueue(q);
|
||||
|
||||
// At this point, we have created a single node (Node 0) and a
|
||||
// single PointToPointNetDevice (NetDevice 0) and added a
|
||||
|
||||
@@ -207,14 +207,14 @@ PointToPointNetDevice::Attach (Ptr<PointToPointChannel> ch)
|
||||
return true;
|
||||
}
|
||||
|
||||
void PointToPointNetDevice::AddQueue (Ptr<Queue> q)
|
||||
void PointToPointNetDevice::SetQueue (Ptr<Queue> q)
|
||||
{
|
||||
NS_LOG_FUNCTION (this << q);
|
||||
|
||||
m_queue = q;
|
||||
}
|
||||
|
||||
void PointToPointNetDevice::AddReceiveErrorModel (Ptr<ErrorModel> em)
|
||||
void PointToPointNetDevice::SetReceiveErrorModel (Ptr<ErrorModel> em)
|
||||
{
|
||||
NS_LOG_FUNCTION ("(" << em << ")");
|
||||
|
||||
|
||||
@@ -121,7 +121,7 @@ public:
|
||||
* @param queue a pointer to the queue for which object is assuming
|
||||
* ownership.
|
||||
*/
|
||||
void AddQueue (Ptr<Queue> queue);
|
||||
void SetQueue (Ptr<Queue> queue);
|
||||
/**
|
||||
* Attach a receive ErrorModel to the PointToPointNetDevice.
|
||||
*
|
||||
@@ -131,7 +131,7 @@ public:
|
||||
* @see ErrorModel
|
||||
* @param em a pointer to the ErrorModel
|
||||
*/
|
||||
void AddReceiveErrorModel(Ptr<ErrorModel> em);
|
||||
void SetReceiveErrorModel(Ptr<ErrorModel> em);
|
||||
/**
|
||||
* Receive a packet from a connected PointToPointChannel.
|
||||
*
|
||||
|
||||
@@ -44,10 +44,10 @@ PointToPointTest::RunTests (void)
|
||||
|
||||
devA->Attach (channel);
|
||||
devA->SetAddress (Mac48Address::Allocate ());
|
||||
devA->AddQueue (CreateObject<DropTailQueue> ());
|
||||
devA->SetQueue (CreateObject<DropTailQueue> ());
|
||||
devB->Attach (channel);
|
||||
devB->SetAddress (Mac48Address::Allocate ());
|
||||
devB->AddQueue (CreateObject<DropTailQueue> ());
|
||||
devB->SetQueue (CreateObject<DropTailQueue> ());
|
||||
|
||||
a->AddDevice (devA);
|
||||
b->AddDevice (devB);
|
||||
|
||||
@@ -170,12 +170,12 @@ PointToPointHelper::Install (Ptr<Node> a, Ptr<Node> b)
|
||||
devA->SetAddress (Mac48Address::Allocate ());
|
||||
a->AddDevice (devA);
|
||||
Ptr<Queue> queueA = m_queueFactory.Create<Queue> ();
|
||||
devA->AddQueue (queueA);
|
||||
devA->SetQueue (queueA);
|
||||
Ptr<PointToPointNetDevice> devB = m_deviceFactory.Create<PointToPointNetDevice> ();
|
||||
devB->SetAddress (Mac48Address::Allocate ());
|
||||
b->AddDevice (devB);
|
||||
Ptr<Queue> queueB = m_queueFactory.Create<Queue> ();
|
||||
devB->AddQueue (queueB);
|
||||
devB->SetQueue (queueB);
|
||||
Ptr<PointToPointChannel> channel = m_channelFactory.Create<PointToPointChannel> ();
|
||||
devA->Attach (channel);
|
||||
devB->Attach (channel);
|
||||
|
||||
Reference in new issue
Block a user