Concepts of Object in Java
Concepts of Object in Java
.~
CONCEPTUAL PROBLEMS
1. 2. 3. 4.
An
- [object] [Abstraction]
is the way of combining both data and the functions that operate on that data under a single unit. [Encapsulation] can be defined as a software bundle of variables and related methods. and . _
[Object]
[characteristics,behaviour] [mes~ges]
.
The data in an object is accessed through the member functions of the object known as The real world objects are implemented variables or data items called The in software form by representing
[methods/memberJunctions]
their state through
The values of data member or member variables at any given point of time determine an object's
(i) Characteristics / attributes are implemented through member variables or data items of the object. (ii) Behaviour is implemented through member functions called methods. (iii) Data and methods are encapsulated into one unit and given a unique name to give it identity.
IJ
What do you mean by Abstraction and Encapsulation ? How are these two terms interrelated?
SOLUTION. Abstraction background details.
including
the
Encapsulation is the act of combining both data and the functions that operate on the data under a single unit. ncapsulation, in a way,_ implements abstraction. '<. ,
II
Encapsulation is one of the mqj()_r properties of OOP. How is it implemented in softWare terms ?
SOLUTION. Encapsulation is 'a way to implement data hiding and abstraction by wrapping up data arid associated functions into a single unit called object.