Thursday 15 March 2012


  When you have interview, it is very Common question that you have to know about Object Oriented Programming (OOP) is...

     Three main concepts?
Inheritance:  Child: parent
Class can associate with each other a ‘child and parent’ relationship. They are share similar properties and method (4 wheels and doors). ‘Car is parent class and SUV and Sport have child class.
Encapsulation:  Like  private, protected and public class in ASP.NET
A class having an interface and this class is available to use. (Break or gas class for vehicle). The data for the object are hidden behind its interface. Purpose is keeping the class logic 'unchangeable'.
Polymorphism: Like Virtual class in ASP.NET
It is possible to call the method without worrying about its internal type; this allows ignoring the details of special classes.

No comments:

Post a Comment