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.
SourceApplication(bool allowPacketSocket=true)
Constructor.
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.
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.
void CancelEvents() override
Cancel all pending events.
static constexpr uint16_t DEFAULT_PORT
default port
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).
void SetRemote(const Address &ip, uint16_t port)
set the remote address and port
void DoStartApplication() override
Application specific startup code for child subclasses.
static void Send(Ptr< NetDevice > dev, int level, std::string emuMode)
#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.