27 #include "ns3/nstime.h"
28 #include "ns3/simulator.h"
43 .AddAttribute (
"StartTime",
"Time at which the application will start",
47 .AddAttribute (
"StopTime",
"Time at which the application will stop",
void SetStopTime(Time stop)
Specify application stop time.
Simulation virtual time values and global simulation resolution.
#define NS_LOG_FUNCTION(parameters)
If log level LOG_FUNCTION is enabled, this macro will output all input parameters separated by "...
#define NS_OBJECT_ENSURE_REGISTERED(type)
Register the class in the ns-3 factory.
static TypeId GetTypeId(void)
Get the type ID.
#define NS_LOG_COMPONENT_DEFINE(name)
Define a Log component with a specific name.
virtual void DoDispose(void)
This method is called by Object::Dispose or by the object's destructor, whichever comes first...
static EventId Schedule(Time const &time, MEM mem_ptr, OBJ obj)
Schedule an event to expire at the relative time "time" is reached.
Ptr< const AttributeChecker > MakeTimeChecker(const Time min, const Time max)
Helper to make a Time checker with bounded range.
virtual void DoInitialize(void)
This method is called only once by Object::Initialize.
Attribute for objects of type ns3::Time.
virtual void StartApplication(void)
Application specific startup code.
Ptr< Node > GetNode() const
Time m_stopTime
The simulation time that the application will end.
virtual void DoDispose(void)
This method is called by Object::Dispose or by the object's destructor, whichever comes first...
Ptr< Node > m_node
The node that this application is installed on.
EventId m_startEvent
The event that will fire at m_startTime to start the application.
void SetNode(Ptr< Node > node)
Time TimeStep(uint64_t ts)
virtual void StopApplication(void)
Application specific shutdown code.
Time Seconds(double value)
Construct a Time in the indicated unit.
void Cancel(void)
This method is syntactic sugar for the ns3::Simulator::cancel method.
EventId m_stopEvent
The event that will fire at m_stopTime to end the application.
a base class which provides memory management and object aggregation
Time m_startTime
The simulation time that the application will start.
a unique identifier for an interface.
TypeId SetParent(TypeId tid)
void SetStartTime(Time start)
Specify application start time.
virtual void DoInitialize(void)
This method is called only once by Object::Initialize.