OOPS Concept
Concept of OOPs
• Class
• Object
• Encapsulation
• Abstraction
• Inheritance
• Polymorphism
Class
• The class can be defined as a collection of attributes and
member function.
• For example: if you have an employee class, then it
should contain an attribute and method, i.e. an email id,
name, age, salary, etc.
Object
• Object is an instance of a class
• The object is an entity that has state and behavior.
• It may be any real-world object like the mouse, keyboard,
chair, table, pen, etc.
Encapsulation
• Encapsulation is a
mechanism of
wrapping the
variables and
methods together
as a single unit.
Abstraction
• Abstraction is the concept
of object-oriented
programming that "shows"
only essential attributes
and "hides" additional
information. The main
purpose of abstraction is
hiding the additional
details from the users
Inheritance
• Inheritance is a process of
creating a new class(Child
class) from existing
class(Parent Class)
Polymorphism
• Poly means ‘many’, and
morph means ‘form’
• Polymorphism allows us to
perform a single action in
different ways
• i.e., Single Entity can
behave in different way

OOPS Concept.pptx

  • 1.
  • 2.
    Concept of OOPs •Class • Object • Encapsulation • Abstraction • Inheritance • Polymorphism
  • 3.
    Class • The classcan be defined as a collection of attributes and member function. • For example: if you have an employee class, then it should contain an attribute and method, i.e. an email id, name, age, salary, etc.
  • 4.
    Object • Object isan instance of a class • The object is an entity that has state and behavior. • It may be any real-world object like the mouse, keyboard, chair, table, pen, etc.
  • 5.
    Encapsulation • Encapsulation isa mechanism of wrapping the variables and methods together as a single unit.
  • 6.
    Abstraction • Abstraction isthe concept of object-oriented programming that "shows" only essential attributes and "hides" additional information. The main purpose of abstraction is hiding the additional details from the users
  • 7.
    Inheritance • Inheritance isa process of creating a new class(Child class) from existing class(Parent Class)
  • 8.
    Polymorphism • Poly means‘many’, and morph means ‘form’ • Polymorphism allows us to perform a single action in different ways • i.e., Single Entity can behave in different way