![]() |
|
NET platform does not support multiple inheritance. Do not confuse multilevel inheritance with multiple inheritance. With multiple inheritance we can have a subclass that inherits from two classes at the same time. Let’s suppose we have an application that has a class Customers and another class Vendors. If you wanted to combine these two classes into one CustomerVendor class it would be a combination of Customers and Vendors just like the diagram below. Business - Directory of business/finance/loan/mortgage related partner sites Computers - Directory of computer hardware/software/peripheral related partner sites Internet - Directory of webhosting/webdesign/internet marketing related partner sites Software - Directory of software related partner sites Web Design - Directory of web design/development related partner sites Web Hosting - Directory of web hosting related partner sites Web Promotion - Directory of search engine optimization/internet marketing related partner sites Web Resources - Directory of other web related partner sites Recreation - Directory of travel/hotel/cruise related partner sites Casino - Directory of online gambling/poker/blackjack/roulette related partner sites Health - Directory of online pharmacy/hospital/health related partner sites Shopping - Directory of online shopping/gift related partner sites Miscellaneous - Directory of all other partner sites
Multiple inheritance is complex and can be dangerous. The advantages of code re-usage prevail over complexity is up to your choice. Multiple inheritance is not supported by VB.NET or .Net platform. Instead of multiple inheritance we can use multiple interfaces to achieve similar effect to multiple inheritance. In VB.NET all objects have a primary or native interface, which is composed of properties, events, methods or member variables declared using Public keyword. Objects can implement also secondary interfaces by using Implement keyword. |
| © Copyright 2006 YourBestWebMaster.com All Rights Reserved. |