16#include "ns3/deprecated.h"
17#include "ns3/event-id.h"
18#include "ns3/ipv4-address.h"
20#include <ns3/traced-callback.h>
a polymophic address class
An identifier for simulation events.
Smart pointer class similar to boost::intrusive_ptr.
A low-level Socket API based loosely on the BSD Socket API.
Base class for source applications.
Simulation virtual time values and global simulation resolution.
Forward calls to a chain of Callback.
a unique identifier for an interface.
Time m_interval
Packet inter-send time.
std::optional< uint16_t > m_peerPort
Remote peer port (deprecated) // NS_DEPRECATED_3_44.
uint64_t GetTotalTx() const
uint64_t m_totalTx
Total bytes sent.
std::string m_peerString
Remote peer address string.
uint32_t m_sent
Counter for sent packets.
Ptr< Socket > m_socket
Socket.
void SetPort(uint16_t port)
Set the remote port (temporary function until deprecated attributes are removed)
TracedCallback< Ptr< const Packet >, const Address &, const Address & > m_txTraceWithAddresses
Callbacks for tracing the packet Tx events, includes source and destination addresses.
static constexpr uint16_t DEFAULT_PORT
default port
void Send()
Send a packet.
static TypeId GetTypeId()
Get the type ID.
EventId m_sendEvent
Event to send the next packet.
uint32_t m_size
Size of the sent packet (including the SeqTsHeader)
uint32_t m_count
Maximum number of packets the application will send.
uint16_t GetPort() const
Get the remote port (temporary function until deprecated attributes are removed)
Address GetRemote() const
Get the remote address (temporary function until deprecated attributes are removed)
TracedCallback< Ptr< const Packet > > m_txTrace
Traced Callback: transmitted packets.
void StartApplication() override
Application specific startup code.
void StopApplication() override
Application specific shutdown code.
void SetRemote(const Address &ip, uint16_t port)
set the remote address and port
#define NS_DEPRECATED_3_44(msg)
Tag for things deprecated in version ns-3.44.
Every class exported by the ns3 library is enclosed in the ns3 namespace.