top button
Flag Notify
    Connect to us
      Site Registration

Site Registration

What is Encapsulation in the context of OOPS?

+2 votes
432 views
What is Encapsulation in the context of OOPS?
posted Apr 8, 2014 by Vishvachi Tiwari

Share this question
Facebook Share Button Twitter Share Button LinkedIn Share Button

1 Answer

+1 vote

Encapsulation is referred to one of the following two notions.
1) Data hiding: A language feature to restrict access to members of an object. For example, private and protected members in C++.
2) Bundling of data and methods together: Data and methods that operate on that data are bundled together.

answer Apr 8, 2014 by Atul Mishra
Similar Questions
0 votes

Do u know about planning or implementing OOP methdology access to array methods in PHP in future. Like show code later:

$a = new Array();
$a->append("hello");
$a->shift();
$p = $a->pop();

$b = Array::fill(fill_char="*", count=20);
$b->pop();
...