MikeW
Nov 10th, 2001, 09:38 AM
Howzit,
Been out of the hands-on game for a while, so while I understand the principles, have a question on implementation:
The one scenario - I'm creating a component (inherits from System.ComponentModel.Component). However, this component is also a collection, so in a perfect world I would've ALSO inherited from System.Collections.CollectionBase).
The second scenario - I have an Employee class, which inherits from a Person class. The Employee class is also a component so must also inherit from System.ComponentModel.Component.
.Net classes do not support multiple inheritance. I understand though that I can get around this using an interface. Any ideas? A source listing'd be useful.
Thanks ia.
Mike
Been out of the hands-on game for a while, so while I understand the principles, have a question on implementation:
The one scenario - I'm creating a component (inherits from System.ComponentModel.Component). However, this component is also a collection, so in a perfect world I would've ALSO inherited from System.Collections.CollectionBase).
The second scenario - I have an Employee class, which inherits from a Person class. The Employee class is also a component so must also inherit from System.ComponentModel.Component.
.Net classes do not support multiple inheritance. I understand though that I can get around this using an interface. Any ideas? A source listing'd be useful.
Thanks ia.
Mike