Ask a Teacher



what is the relation between encapsulation &abstraction?

Abstraction and Encapsulation in Java are two important Object oriented programming concept and they are completely different to each other. Only similarity between Abstraction and Encapsulation is that they are OOPS concept, other than that they mean two different things. Abstraction represent taking out the behavior from How exactly its implemented, one example of abstraction in Java is interface while Encapsulation means hiding details of implementation from outside world so that when things change no body gets affected.


comments powered by Disqus