[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [ns] multiple inheritance



I would like to know how do you go about doing this in .tcl file. As in
the file tcl/lib/ns-bsnode.tcl, they define BaseSattionNode as follows

Class Node/MobileNode/BaseStationNode -superclass Node/MobileNode

now if i want to have multiple inheritance here what will i do??

Thanks
Bhagya


On Wed, 30 May 2001, Debojyoti Dutta wrote:

> you can define a class X to inherit from Y, Z
> 
> class X : public Y, Z {
> 
> }
> 
> -debo
> 
> 
> On Wed, 30 May 2001, Bhagyalaxmi Bethala wrote:
> 
> > hi,
> >   Does anybody know how can a new class be created by inheriting it from
> > more than one class. For example, in the BaseStationNode, of
> > ns../tcl/libns-bsnode.tcl, they say base station is actually a hybrid
> > between mobilenode and hiernode. Can this be done?? If yes how should it
> > be done??
> > 
> > Thanks in advance
> > Bhagya
> > 
> > 
> > 
> 
>