Public Member Functions | Static Public Member Functions | Protected Member Functions | Private Member Functions | Private Attributes

ns3::Ping6 Class Reference
[Ping6]

A ping6 application. More...

#include <ping6.h>

Inheritance diagram for ns3::Ping6:
Inheritance graph
[legend]
Collaboration diagram for ns3::Ping6:
Collaboration graph
[legend]

List of all members.

Public Member Functions

 Ping6 ()
 Constructor.
virtual ~Ping6 ()
 Destructor.
void SetLocal (Ipv6Address ipv6)
 Set the local address.
void SetRemote (Ipv6Address ipv6)
 Set the remote peer.
void SetIfIndex (uint32_t ifIndex)
 Set the out interface index. This is to send to link-local (unicast or multicast) address when a node has multiple interfaces.

Static Public Member Functions

static TypeId GetTypeId ()
 Get the type ID.

Protected Member Functions

virtual void DoDispose ()
 Dispose this object;.

Private Member Functions

virtual void StartApplication ()
 Start the application.
virtual void StopApplication ()
 Stop the application.
void ScheduleTransmit (Time dt)
 Schedule sending a packet.
void Send ()
 Send a packet.
void HandleRead (Ptr< Socket > socket)
 Receive method.

Private Attributes

Ipv6Address m_address
 Peer IPv6 address.
uint32_t m_count
 Number of "Echo request" packets that will be sent.
uint32_t m_sent
 Number of packets sent.
uint32_t m_size
 Size of the packet.
Time m_interval
 Intervall between packets sent.
Ipv6Address m_localAddress
 Local address.
Ipv6Address m_peerAddress
 Peer address.
Ptr< Socketm_socket
 Local socket.
uint16_t m_seq
 Sequence number.
EventId m_sendEvent
 Event ID.
uint32_t m_ifIndex
 Out interface (i.e. for link-local communication).

Detailed Description

A ping6 application.


Member Function Documentation

static TypeId ns3::Ping6::GetTypeId ( void   )  [static]

Get the type ID.

This method returns the TypeId associated to ns3::Ping6.

Returns:
type ID

This object is accessible through the following paths with Config::Set and Config::Connect:

  • /NodeList/[i]/ApplicationList/[i]/$ns3::Ping6

Attributes defined for this type:

  • MaxPackets: The maximum number of packets the application will send
  • Interval: The time to wait between packets
    • Set with class: TimeValue
    • Underlying type: Time
    • Initial value: 1000000000ns
    • Flags: construct write read
  • RemoteIpv6: The Ipv6Address of the outbound packets
    • Set with class: Ipv6AddressValue
    • Underlying type: Ipv6Address
    • Initial value: 0000:0000:0000:0000:0000:0000:0000:0000
    • Flags: construct write read
  • LocalIpv6: Local Ipv6Address of the sender
    • Set with class: Ipv6AddressValue
    • Underlying type: Ipv6Address
    • Initial value: 0000:0000:0000:0000:0000:0000:0000:0000
    • Flags: construct write read
  • PacketSize: Size of packets generated

No TraceSources defined for this type.

Reimplemented from ns3::Application.

void ns3::Ping6::HandleRead ( Ptr< Socket socket  )  [private]

Receive method.

Parameters:
socket socket that receive a packet
void ns3::Ping6::ScheduleTransmit ( Time  dt  )  [private]

Schedule sending a packet.

Parameters:
dt interval between packet
void ns3::Ping6::SetIfIndex ( uint32_t  ifIndex  ) 

Set the out interface index. This is to send to link-local (unicast or multicast) address when a node has multiple interfaces.

Parameters:
ifIndex interface index
void ns3::Ping6::SetLocal ( Ipv6Address  ipv6  ) 

Set the local address.

Parameters:
ipv6 the local IPv6 address
void ns3::Ping6::SetRemote ( Ipv6Address  ipv6  ) 

Set the remote peer.

Parameters:
ipv6 IPv6 address of the peer

The documentation for this class was generated from the following files: