[Ns-bugs] [Bug 147] base class for reference counted objects
bugzilla-daemon@nsnam-www.ece.gatech.edu
bugzilla-daemon at nsnam-www.ece.gatech.edu
Mon Mar 17 09:58:32 PDT 2008
http://www.nsnam.org/bugzilla/show_bug.cgi?id=147
------- Comment #4 from mathieu.lacage at sophia.inria.fr 2008-03-17 12:58 -------
(In reply to comment #3)
> (In reply to comment #2)
> > Object should not because the implementation is very different/incompatible.
> > All the others could but they already derive from the ObjectBase class so doing
> > what you suggest now would require some multiple inheritance which I would
> > rather avoid.
> >
> > Since I plan to remove eventually the ObjectBase class from their inheritance
> > tree, could we defer using RefCountBase in the classes which derive from
> > ObjectBase until I have done that removal ?
> >
> > Other than that, looks good to me.
> >
>
> Instead, we could add Ref and Unref into ObjectBase, and then eventually
> renaming ObjectBase to RefCountedBase? There is no problem with Object
The plan is to move the attribute system to ObjectBase, not the reference
counting to allow classes which do not want to be refcounted to get the
attributes anyway.
The only reason why they inherit from ObjectBase now is that I needed to do
this as a temporary hack to get the attributes working a few weeks ago and
never removed it since then because no one reminded me of the merge of
RefCountedBase.
> inheriting from this class too (as it does now), because it would just
> reimplement Ref and Unref with its own implementation, provided we make the
> ObjectBase::Ref and Unref methods virtual.
We cannot make these virtual for performance reasons.
--
Configure bugmail: http://www.nsnam.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.
More information about the Ns-bugs
mailing list