OOP CONCEPTS


OOP CONCEPTS



Procedural Paradigm, Object Oriented programming, Object, Class, Data Abstraction, Encapsulation, Modularity, Advantages of Object oriented programming
Paradigm-: It means organizing principle of a program. It is an approach to programming.
Procedural ParadigmIn procedural programming paradigm, the emphasis is on doing things i.e., the procedure or the algorithm. The data takes the back seat in procedural programming paradigm. Also, this paradigm does not model real world well.
Object Oriented programmingThe object oriented programming paradigm models the real world well and overcomes the shortcomings of procedural paradigm. It views a problem in terms of objects and thus emphasizes on both procedures as well as data.
The following are the basic concepts used in object-oriented programming.
Object-: An object is an identifiable entity with some characteristics and behavior.
Class-: A class represents a group of objects that share common properties, behavior and relationships.
Data Abstraction-: Abstraction refers to act of representing essential features without including the background details or explanations.
Encapsulation-: The wrapping up of data and associated functions into a single unit is known as Encapsulation. Encapsulation implements data abstraction.
Modularity-: Modularity is the property of a system that has been decomposed into a set of cohesive and loosely coupled modules.
Inheritance-: It is the capability of one class of things to inherit capabilities or properties from another class.
Base and sub classes-: The class whose properties are inherited is called base class (or superclass) and the class that inherits the properties is known as derived class(or subclass).
Derived Class :- The class, which inherits from other classes is called derived class or Subclass.
Polymorphism-: It is the ability for a message or data to be processed in more than one form. Polymorphism is a property by which the same message can be sent to objects of several different classes. Polymorphism is implemented in C++ through virtual functions and overloading- function overloading and operator overloading.
Advantages of Object oriented programming.
Software complexity can be easily managed
Object-oriented systems can be easily upgraded 
It is quite easy to partition the work in a project based on object
class enforce data-hiding, abstraction & encapsulation
A class groups its members into three sections : private, protected, and public. The private and protected members remain hidden from outside world. Thus through private and protected members, a class enforces data-hiding.
The outside world is given only the essential and necessary information through public members, rest of the things remain hidden, which is nothing but abstraction. Abstraction means representation of essential features without including the background details and explanation.

No comments:

Post a Comment