14#include "ns3/callback.h"
15#include "ns3/deprecated.h"
16#include "ns3/ipv4-address.h"
17#include "ns3/object.h"
18#include "ns3/socket.h"
L4 Protocol abstract base class.
Ipv4 addresses are stored in host order in this class.
virtual int32_t GetInterfaceForAddress(Ipv4Address address) const =0
Return the interface number of the interface that has been assigned the specified IP address.
virtual bool GetIpForward() const =0
Get the IP forwarding state.
virtual bool GetStrongEndSystemModel() const =0
Get the Strong End System Model status.
virtual void SetIpForward(bool forward)=0
Set or unset the IP forwarding state.
virtual void SetStrongEndSystemModel(bool model)=0
Set or unset the Strong End System Model.
virtual void DeleteRawSocket(Ptr< Socket > socket)=0
Deletes a particular raw socket.
virtual bool IsForwarding(uint32_t interface) const =0
virtual Ptr< Ipv4RoutingProtocol > GetRoutingProtocol() const =0
Get the routing protocol to be used by this Ipv4 stack.
virtual void SetMetric(uint32_t interface, uint16_t metric)=0
virtual void SetRoutingProtocol(Ptr< Ipv4RoutingProtocol > routingProtocol)=0
Register a new routing protocol to be used by this Ipv4 stack.
virtual void Insert(Ptr< IpL4Protocol > protocol)=0
virtual uint32_t GetNAddresses(uint32_t interface) const =0
virtual void Remove(Ptr< IpL4Protocol > protocol)=0
virtual bool RemoveAddress(uint32_t interface, Ipv4Address address)=0
Remove the given address on named Ipv4 interface.
virtual uint16_t GetMtu(uint32_t interface) const =0
virtual Ipv4InterfaceAddress GetAddress(uint32_t interface, uint32_t addressIndex) const =0
Because addresses can be removed, the addressIndex is not guaranteed to be static across calls to thi...
virtual uint32_t AddInterface(Ptr< NetDevice > device)=0
virtual void SendWithHeader(Ptr< Packet > packet, Ipv4Header ipHeader, Ptr< Ipv4Route > route)=0
virtual Ptr< IpL4Protocol > GetProtocol(int protocolNumber) const =0
virtual void SetUp(uint32_t interface)=0
virtual Ipv4Address SelectSourceAddress(Ptr< const NetDevice > device, Ipv4Address dst, Ipv4InterfaceAddress::InterfaceAddressScope_e scope)=0
Return the first primary source address with scope less than or equal to the requested scope,...
virtual Ptr< NetDevice > GetNetDevice(uint32_t interface)=0
virtual void Send(Ptr< Packet > packet, Ipv4Address source, Ipv4Address destination, uint8_t protocol, Ptr< Ipv4Route > route)=0
virtual bool IsDestinationAddress(Ipv4Address address, uint32_t iif) const =0
Determine whether address and interface corresponding to received packet can be accepted for local de...
virtual void Insert(Ptr< IpL4Protocol > protocol, uint32_t interfaceIndex)=0
Add a L4 protocol to a specific interface.
static const uint32_t IF_ANY
interface wildcard, meaning any interface
static TypeId GetTypeId()
Get the type ID.
virtual Ptr< IpL4Protocol > GetProtocol(int protocolNumber, int32_t interfaceIndex) const =0
Get L4 protocol by protocol number for the specified interface.
virtual int32_t GetInterfaceForDevice(Ptr< const NetDevice > device) const =0
virtual int32_t GetInterfaceForPrefix(Ipv4Address address, Ipv4Mask mask) const =0
Return the interface number of first interface found that has an Ipv4 address within the prefix speci...
virtual void SetDown(uint32_t interface)=0
virtual Ipv4Address SourceAddressSelection(uint32_t interface, Ipv4Address dest)=0
Choose the source address to use with destination address.
virtual bool RemoveAddress(uint32_t interface, uint32_t addressIndex)=0
Remove the address at addressIndex on named interface.
virtual uint16_t GetMetric(uint32_t interface) const =0
virtual bool AddAddress(uint32_t interface, Ipv4InterfaceAddress address)=0
virtual uint32_t GetNInterfaces() const =0
virtual void Remove(Ptr< IpL4Protocol > protocol, uint32_t interfaceIndex)=0
Remove a L4 protocol from a specific interface.
virtual Ptr< Socket > CreateRawSocket()=0
Creates a raw socket.
virtual void SetForwarding(uint32_t interface, bool val)=0
virtual bool IsUp(uint32_t interface) const =0
a class to store IPv4 address information on an interface
InterfaceAddressScope_e
Address scope.
a class to represent an Ipv4 address mask
Abstract base class for IPv4 routing protocols.
Network layer to device interface.
Object()
Caller graph was not generated because of its size.
Smart pointer class similar to boost::intrusive_ptr.
a unique identifier for an interface.
Every class exported by the ns3 library is enclosed in the ns3 namespace.