--- a/src/simulator/event-id.cc Thu Jul 26 16:04:54 2007 +0200
+++ b/src/simulator/event-id.cc Fri Jul 27 09:50:21 2007 +0200
@@ -55,7 +55,7 @@
return !IsExpired ();
}
EventImpl *
-EventId::GetEventImpl (void) const
+EventId::PeekEventImpl (void) const
{
return m_eventImpl;
}
--- a/src/simulator/event-id.h Thu Jul 26 16:04:54 2007 +0200
+++ b/src/simulator/event-id.h Fri Jul 27 09:50:21 2007 +0200
@@ -51,7 +51,7 @@
* they are supposed to be invoked only by
* subclasses of the Scheduler base class.
*/
- EventImpl *GetEventImpl (void) const;
+ EventImpl *PeekEventImpl (void) const;
uint64_t GetTs (void) const;
uint32_t GetUid (void) const;
private:
--- a/src/simulator/scheduler-heap.cc Thu Jul 26 16:04:54 2007 +0200
+++ b/src/simulator/scheduler-heap.cc Fri Jul 27 09:50:21 2007 +0200
@@ -225,7 +225,7 @@
void
SchedulerHeap::RealInsert (EventId id)
{
- EventImpl *event = id.GetEventImpl ();
+ EventImpl *event = id.PeekEventImpl ();
Scheduler::EventKey key;
key.m_ts = id.GetTs ();
key.m_uid = id.GetUid ();
@@ -256,7 +256,7 @@
{
if (uid == m_heap[i].second.m_uid)
{
- NS_ASSERT (m_heap[i].first == id.GetEventImpl ());
+ NS_ASSERT (m_heap[i].first == id.PeekEventImpl ());
Exch (i, Last ());
m_heap.pop_back ();
TopDown (i);
--- a/src/simulator/scheduler-list.cc Thu Jul 26 16:04:54 2007 +0200
+++ b/src/simulator/scheduler-list.cc Fri Jul 27 09:50:21 2007 +0200
@@ -70,7 +70,7 @@
SchedulerList::RealInsert (EventId id)
{
Scheduler::EventKey key;
- EventImpl *event = id.GetEventImpl ();
+ EventImpl *event = id.PeekEventImpl ();
key.m_ts = id.GetTs ();
key.m_uid = id.GetUid ();
for (EventsI i = m_events.begin (); i != m_events.end (); i++)
@@ -108,7 +108,7 @@
{
if (i->second.m_uid == id.GetUid ())
{
- NS_ASSERT (id.GetEventImpl () == i->first);
+ NS_ASSERT (id.PeekEventImpl () == i->first);
m_events.erase (i);
return true;
}
--- a/src/simulator/scheduler-map.cc Thu Jul 26 16:04:54 2007 +0200
+++ b/src/simulator/scheduler-map.cc Fri Jul 27 09:50:21 2007 +0200
@@ -90,7 +90,7 @@
void
SchedulerMap::RealInsert (EventId id)
{
- EventImpl *event = id.GetEventImpl ();
+ EventImpl *event = id.PeekEventImpl ();
Scheduler::EventKey key;
key.m_ts = id.GetTs ();
key.m_uid = id.GetUid ();
@@ -126,7 +126,7 @@
key.m_ts = id.GetTs ();
key.m_uid = id.GetUid ();
EventMapI i = m_list.find (key);
- NS_ASSERT (i->second == id.GetEventImpl ());
+ NS_ASSERT (i->second == id.PeekEventImpl ());
m_list.erase (i);
return true;
}
--- a/src/simulator/simulator.cc Thu Jul 26 16:04:54 2007 +0200
+++ b/src/simulator/simulator.cc Fri Jul 27 09:50:21 2007 +0200
@@ -114,7 +114,7 @@
{
while (!m_destroyEvents.empty ())
{
- EventImpl *ev = m_destroyEvents.front ().GetEventImpl ();
+ EventImpl *ev = m_destroyEvents.front ().PeekEventImpl ();
m_destroyEvents.pop_front ();
TRACE ("handle destroy " << ev);
if (!ev->IsCancelled ())
@@ -151,7 +151,7 @@
{
m_log << "e "<<next.GetUid () << " " << next.GetTs () << std::endl;
}
- EventImpl *event = next.GetEventImpl ();
+ EventImpl *event = next.PeekEventImpl ();
event->Invoke ();
delete event;
}
@@ -275,7 +275,7 @@
return;
}
m_events->Remove (ev);
- delete ev.GetEventImpl ();
+ delete ev.PeekEventImpl ();
if (m_logEnable)
{
@@ -306,11 +306,11 @@
}
return true;
}
- if (ev.GetEventImpl () == 0 ||
+ if (ev.PeekEventImpl () == 0 ||
ev.GetTs () < m_currentTs ||
(ev.GetTs () == m_currentTs &&
ev.GetUid () <= m_currentUid) ||
- ev.GetEventImpl ()->IsCancelled ())
+ ev.PeekEventImpl ()->IsCancelled ())
{
return true;
}