[Ns-bugs] [Bug 491] It is painful to enable all checksums
code@nsnam.ece.gatech.edu
code at nsnam.ece.gatech.edu
Mon Apr 27 22:54:11 PDT 2009
http://www.nsnam.org/bugzilla/show_bug.cgi?id=491
--- Comment #10 from Tom Henderson <tomh at tomh.org> 2009-04-28 01:54:11 EDT ---
(In reply to comment #9)
> Forgot to hg add the two new (very small) files.
>
> You now have a singleton object with global configuration information. From
> examples/emu-ping.cc turning on checksums is a one-liner:
>
> System ()->SetAttribute ("CalcChecksum", BooleanValue (true));
>
> The protocols do something like,
>
> BooleanValue b;
> System ()->GetAttribute ("CalcChecksum", b);
>
> if(m_calcChecksum || b.Get ())
> {
> ...
>
I would be fine with this solution, although it does not use one attribute or
global value to set the others, the net user-visible behavior is the same.
--
Configure bugmail: http://www.nsnam.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.
More information about the Ns-bugs
mailing list