Bug 557 - AddInternetStack and AddNscInternetStack are too coarse-grained
AddInternetStack and AddNscInternetStack are too coarse-grained
Status: RESOLVED FIXED
Product: ns-3
Classification: Unclassified
Component: internet
ns-3-dev
All All
: P5 normal
Assigned To: ns-bugs
:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2009-04-24 09:25 UTC by Mathieu Lacage
Modified: 2009-05-29 17:41 UTC (History)
2 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Mathieu Lacage 2009-04-24 09:25:53 UTC
We want to be able to add the ipv4, udp, tcp, and arp stacks separately and do so from InternetStackHelper.

The idea is that InternetStackHelper would need to create only a single object for each element of the stack: UdpL4Protocol, TcpL4Protocol, Ipv4L3Protocol, and, ArpL3Protocol and each of these objects should be aggregated separately to a Node.

This means that:
1) we need to aggregate together multiple objects: TcpL4Protocol must aggregate itself with TcpSocketFactoryImpl. The same for UdpL4Protocol and UdpSocketFactoryImpl, etc.

2) we need to allow each object already-aggregated to a node to be notified whenever a new object is aggregated to the node: this is needed to allow the UdpL4Protocol object to find the node's Ipv4L3Protocol object to register as a layer 4 protocol. So, we need to add support in src/core/object.h|cc for a NotifyNewAggregate virtual method which is invoked by AggregateObject whenever a new object is aggregated to an existing aggregate.
Comment 1 Tom Henderson 2009-05-29 17:41:28 UTC
changeset e20a31541404