a simulation event More...
#include <event-impl.h>
Public Member Functions | |
void | Invoke (void) |
void | Cancel (void) |
bool | IsCancelled (void) |
Static Public Member Functions | |
static void | SetEventLock (EventLock *eventLock) |
static void | SetNoEventLock (void) |
a simulation event
Each subclass of this base class represents a simulation event. The EventImpl::Invoke method will be invoked by the simulation engine when the time associated to this event expires. This class is obviously (there are Ref and Unref methods) reference-counted and most subclasses are usually created by one of the many Simulator::Schedule methods.
void ns3::EventImpl::Cancel | ( | void | ) |
Marks the event as 'canceled'. The event will not be removed from the event list but the simulation engine will check its canceled status before calling Invoke.
void ns3::EventImpl::Invoke | ( | void | ) |
Called by the simulation engine to notify the event that it has expired.
bool ns3::EventImpl::IsCancelled | ( | void | ) |
Invoked by the simulation engine before calling Invoke.
static void ns3::EventImpl::SetEventLock | ( | EventLock * | eventLock | ) | [static] |
Provide a mutex with Lock and Unlock methods to the event implementation so that it can do cheap (from the perspective of event memory usage) critical sections (mutual exclusion) in the reference counting code.
eventLock | Pointer to the EventLock object used to contain the underlying mutex. |
static void ns3::EventImpl::SetNoEventLock | ( | void | ) | [static] |
Remove any reference the event implementation code may hold to to an existing EventLock and disable the event locking feature.