add Application::SetNode and NetDevice::SetNode, use them from Node::AddApplication and Node::AddDevice. kill useless "Node" attributes.

This commit is contained in:
Mathieu Lacage committed 2008-03-13 11:10:38 -07:00
1 parent 82ea02b8ec
commit 0601ecd105
43 files changed
+232 -328

No files matched your search

+6 -4
View File
@@ -40,10 +40,6 @@ Application::GetTypeId (void)
{
static TypeId tid = TypeId ("Application")
.SetParent<Object> ()
.AddAttribute ("Node", "The on which this application resides",
Ptr<Node> (0),
MakePtrAccessor (&Application::m_node),
MakePtrChecker<Node> ())
;
return tid;
}
@@ -92,6 +88,12 @@ Ptr<Node> Application::GetNode() const
return m_node;
}
void
Application::SetNode (Ptr<Node> node)
{
m_node = node;
}
// Protected methods
// StartApp and StopApp will likely be overridden by application subclasses
void Application::StartApplication()