Bug 783 - feature request: add API to application helpers to expose Socket::BindToNetDevice
feature request: add API to application helpers to expose Socket::BindToNetD...
Status: NEW
Product: ns-3
Classification: Unclassified
Component: routing
pre-release
All All
: P5 normal
Assigned To: ns-bugs
:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2010-01-04 00:40 EST by Tom Henderson
Modified: 2010-01-04 00:40 EST (History)
1 user (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Tom Henderson 2010-01-04 00:40:12 EST
One of the open issues when bug 742 closed was to add API to PacketSinkHelper to allow a user to bind to a device.  This need is probably not limited to PacketSinkHelper.

This ns-3-users thread also raises the issue:
http://groups.google.com/group/ns-3-users/browse_thread/thread/62e922adfdcfe3aa

Probably this can be dealt with by adding an pointer or integer attribute similar to the way the address ("Local") is supported:

    .AddAttribute ("Local", "The Address on which to Bind the rx socket.",
                   AddressValue (),
                   MakeAddressAccessor (&PacketSink::m_local),
                   MakeAddressChecker ())

and to extend the PacketSinkHelper constructor or add another method there.  It would probably also help to add support to the helper to get a handle to the packet sinks that are created (right now, the helper is oriented towards creating a bunch of packet sink objects but returning an application container).