diff --git a/CHANGES.html b/CHANGES.html index 7003d49c0..1beecb862 100644 --- a/CHANGES.html +++ b/CHANGES.html @@ -46,11 +46,83 @@ us a note on ns-developers mailing list.
+void
+SimpleChannel::Send (Ptr<Packet> p, uint16_t protocol,
+ Mac48Address to, Mac48Address from,
+ Ptr<SimpleNetDevice> sender)
+{
+ for (std::vector<Ptr<SimpleNetDevice> >::const_iterator i = m_devices.begin (); i != m_devices.end (); ++i)
+ {
+ Ptr<SimpleNetDevice> tmp = *i;
+ if (tmp == sender)
+ {
+ continue;
+ }
+ Simulator::ScheduleNow (&SimpleNetDevice::Receive, tmp, p->Copy (), protocol, to, from);
+ }
+}
+
+After:
+
+void
+SimpleChannel::Send (Ptr<Packet> p, uint16_t protocol,
+ Mac48Address to, Mac48Address from,
+ Ptr<SimpleNetDevice> sender)
+{
+ for (std::vector<Ptr<SimpleNetDevice> >::const_iterator i = m_devices.begin (); i != m_devices.end (); ++i)
+ {
+ Ptr<SimpleNetDevice> tmp = *i;
+ if (tmp == sender)
+ {
+ continue;
+ }
+ Simulator::ScheduleWithContext (tmp->GetNode ()->GetId (), Seconds (0),
+ &SimpleNetDevice::Receive, tmp, p->Copy (), protocol, to, from);
+ }
+}
+
+
++Ptr<Scheduler> sched = CreateObject<ListScheduler> (); +Simulator::SetScheduler (sched); ++After: +
+ObjectFactory sched;
+sched.SetTypeId ("ns3::ListScheduler");
+Simulator::SetScheduler (sched);
+
+
+