Bug 219

Summary: Ipv4Interface is a poor API
Product: ns-3 Reporter: Craig Dowell <craigdo>
Component: networkAssignee: Tom Henderson <tomh>
Status: RESOLVED FIXED    
Severity: normal CC: ns-bugs
Priority: P2    
Version: pre-release   
Hardware: All   
OS: All   
Bug Depends on:    
Bug Blocks: 384    

Description Craig Dowell 2008-06-11 20:00:44 UTC
Ipv4.h has inconsistent method naming and misleading or duplicated method names.  Related problem with Ipv4RoutingProtocol.

Some methods named Find This or That and return uint32 index.
Some methods named Get This or that and return uint32 index.
Some methods take an index for an Ipv4Interface called i.
Some methods take an index for an Ipv4Interface called ifIndex.
Some methods take an index for an Ipv4Interface called interface.

IfIndex is an overloaded term and shouldn't appear here.

Some methods are misleading.  FindIfIndexForDevice implies there is only one interface allowed per device.

Some methods are duplicated?  FindInterfaceForAddr, GetIfIndexByAddress.

This is not very pretty.
Comment 1 Tom Henderson 2009-02-16 01:02:16 UTC
sliding to ns-3.5
Comment 2 Tom Henderson 2009-05-29 17:39:19 UTC
changeset e20a31541404