Where The Inheritence is useful?How we decide the situation
of inheritence

Answer Posted / gaurav

Inheritance is useful when abstracted logic is required, a real time case, for example your building online store's application all those computer type of products you can define common parent class which would have attributes like brand, processor, RAM, HDD etc. this would be common frame for every product of type computer.
Basically, when you are in situation where you need a common structure you normally create abstract class which should mustInherite.

Is This Answer Correct ?    1 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Are there any parts of the .net framework 3.0 that only work on windows vista?

557


When using razor views, do you have to take any special steps to protect your asp.net mvc application from cross site scripting (xss) attacks?

698


What is renderbody?

544


How to answer for project questions..?

2232


What is the use of web api ? Why web api needed, if you have already restful services using wcf ?

546






What are the 2 ways of adding constraints to a route?

548


Is http stateful or stateless?

547


What is the advantage of mvc?

614


Describe the gac in the .net framework.

572


What is entitycontainer? : Entity framework

577


What is basic authentication in web api?

525


mention what is code first approach and model first approach in entity framework?

626


What filters are executed in the end?

589


mention what is the key advantage of using entity framework or ef?

552


What is the .net framework?

573