ns-3
|
An IPv6 end point, four tuples identification. More...
#include <ipv6-end-point.h>
Public Member Functions | |
Ipv6EndPoint (Ipv6Address addr, uint16_t port) | |
Constructor. | |
~Ipv6EndPoint () | |
Destructor. | |
Ipv6Address | GetLocalAddress () |
Get the local address. | |
void | SetLocalAddress (Ipv6Address addr) |
Set the local address. | |
uint16_t | GetLocalPort () |
Get the local port. | |
void | SetLocalPort (uint16_t port) |
Set the local port. | |
Ipv6Address | GetPeerAddress () |
Get the peer address. | |
uint16_t | GetPeerPort () |
Get the peer port. | |
void | SetPeer (Ipv6Address addr, uint16_t port) |
Set the peer informations (address and port). | |
void | SetRxCallback (Callback< void, Ptr< Packet >, Ipv6Address, uint16_t > callback) |
Set the reception callback. | |
void | SetIcmpCallback (Callback< void, Ipv6Address, uint8_t, uint8_t, uint8_t, uint32_t > callback) |
Set the ICMP callback. | |
void | SetDestroyCallback (Callback< void > callback) |
Set the default destroy callback. | |
void | ForwardUp (Ptr< Packet > p, Ipv6Address addr, uint16_t port) |
Forward the packet to the upper level. | |
void | ForwardIcmp (Ipv6Address src, uint8_t ttl, uint8_t type, uint8_t code, uint32_t info) |
Function called from an L4Protocol implementation to notify an endpoint of an icmp message reception. |
An IPv6 end point, four tuples identification.
ns3::Ipv6EndPoint::Ipv6EndPoint | ( | Ipv6Address | addr, |
uint16_t | port | ||
) |
Constructor.
addr | the IPv6 address |
port | the port |
void ns3::Ipv6EndPoint::ForwardIcmp | ( | Ipv6Address | src, |
uint8_t | ttl, | ||
uint8_t | type, | ||
uint8_t | code, | ||
uint32_t | info | ||
) |
Function called from an L4Protocol implementation to notify an endpoint of an icmp message reception.
src | source IPv6 address |
ttl | time-to-live |
type | ICMPv6 type |
code | ICMPv6 code |
info | ICMPv6 info |
References ns3::Simulator::ScheduleNow().
void ns3::Ipv6EndPoint::ForwardUp | ( | Ptr< Packet > | p, |
Ipv6Address | addr, | ||
uint16_t | port | ||
) |
Forward the packet to the upper level.
p | the packet |
addr | source address |
port | source port |
uint16_t ns3::Ipv6EndPoint::GetLocalPort | ( | void | ) |
uint16_t ns3::Ipv6EndPoint::GetPeerPort | ( | void | ) |
void ns3::Ipv6EndPoint::SetDestroyCallback | ( | Callback< void > | callback | ) |
Set the default destroy callback.
callback | callback function |
void ns3::Ipv6EndPoint::SetIcmpCallback | ( | Callback< void, Ipv6Address, uint8_t, uint8_t, uint8_t, uint32_t > | callback | ) |
Set the ICMP callback.
callback | callback function |
void ns3::Ipv6EndPoint::SetLocalAddress | ( | Ipv6Address | addr | ) |
Set the local address.
addr | the address to set |
void ns3::Ipv6EndPoint::SetLocalPort | ( | uint16_t | port | ) |
Set the local port.
port | the port to set |
void ns3::Ipv6EndPoint::SetPeer | ( | Ipv6Address | addr, |
uint16_t | port | ||
) |
Set the peer informations (address and port).
addr | peer address |
port | peer port |
Referenced by ns3::Ipv6EndPointDemux::Allocate().
void ns3::Ipv6EndPoint::SetRxCallback | ( | Callback< void, Ptr< Packet >, Ipv6Address, uint16_t > | callback | ) |
Set the reception callback.
callback | callback function |