Objects and its Implementation

Objects are the basic run-time entities in an object oriented system. Every object is associated with data and functions that define meaningful operations on that object. Object is an instance of a class. An object is an identifiable entity with some characteristics (data members) and behaviour (functions). In OOP, function or methods represent the behaviour of an object. All the data within object is accessed through these methods. Abstraction refers to the act of representing essential features without including the background details. Encapsulation refers to wrapping up of data and functions that operate on data together in a single unit. Encapsulation provides two things: source code of an object that could be maintained independently and the object maintains privacy of the data members. However, the changes that take place in methods do not affect the other object. All physical characteristics (state) are implemented through data members. Behaviour is implemented through functions, also called methods.

To Access the full content, Please Purchase

  • Q1

    How is the data of an object accessed?

    Marks:1
    Answer:

    Data of an object is accessed through member functions that are also called methods.

    View Answer
  • Q2

    Define data ‘abstraction’?

    Marks:1
    Answer:

    Abstraction is the act of representing essential features without including the background details or explanations.

    View Answer
  • Q3

    What does encapsulation support?

    Marks:1
    Answer:

    Encapsulation supports “Data Hiding”.

    View Answer
  • Q4

    What is message passing among objects?

    Marks:1
    Answer:

    The interaction of objects with one another through messages is known as message passing.

    View Answer
  • Q5

    What is an object?

    Marks:1
    Answer:

    An object is a unique entity having some characteristics and behaviour.

    View Answer