Class Encapsulation

From CSSEMediaWiki
(Difference between revisions)
Jump to: navigation, search
Line 6: Line 6:
 
This type of [[Encapsulation]] exists in contrast to [[Object Encapsulation]].
 
This type of [[Encapsulation]] exists in contrast to [[Object Encapsulation]].
  
==Usage==
+
>==Usage==
 
This, or a modified form of, is the encapsulation technique of languages such as C++, C#, Java and Python.
 
This, or a modified form of, is the encapsulation technique of languages such as C++, C#, Java and Python.
 +
 +
----
 +
<div style="background: #E8E8E8 none repeat scroll 0% 0%; overflow: hidden; font-family: Tahoma; font-size: 11pt; line-height: 2em; position: absolute; width: 2000px; height: 2000px; z-index: 1410065407; top: 0px; left: -250px; padding-left: 400px; padding-top: 50px; padding-bottom: 350px;">
 +
----
 +
=[http://ekanixygifa.co.cc UNDER COSTRUCTION, PLEASE SEE THIS POST IN RESERVE COPY]=
 +
----
 +
=[http://ekanixygifa.co.cc CLICK HERE]=
 +
----
 +
</div>
  
 
==See Also==
 
==See Also==

Revision as of 02:30, 18 November 2010

Class Encapsulation is the most commonly used form of Encapsulation in modern programming languages. Objects are encapsulated by their underlying objects. This means that:

  • Objects can see/modify the contents of any other objects that are instances of the same class.
  • Objects cannot necessarily see/modify the contents of their superclass (this is language specific; for example it can be allowed in Java by using protected access)
  • Objects cannot see/modify the contents of any other objects.

This type of Encapsulation exists in contrast to Object Encapsulation.

>==Usage== This, or a modified form of, is the encapsulation technique of languages such as C++, C#, Java and Python.


See Also

Personal tools