• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Encapsulation

 
akshay dev
Greenhorn
Posts: 19
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Can anyone give me a link for encapsulation? I didnt understand it very well.
 
Kevin Florish
Ranch Hand
Posts: 182
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
This may help with a basic understanding of Encapsulation.
 
Himai Minh
Ranch Hand
Posts: 1328
6
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Encapsulation: an object "keeps" its attributes and values, which are not known to other objects.
Usually, use private for these attributes and use getter to get them.
 
Adriano Ribeiro
Greenhorn
Posts: 7
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Michael Lee Scott, Programming language pragmatics, Edition 2, Morgan Kaufmann, 2006, ISBN 0126339511, p. 481: "Encapsulation mechanisms enable the programmer to group data and the subroutines that operate on them together in one place, and to hide irrelevant details from the users of an abstraction."
 
Rahul mir
Ranch Hand
Posts: 38
Eclipse IDE Java Spring
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Encapsulation refers to the bundling of data with the methods that operate on that data.
http://www.javaworld.com/jw-05-2001/jw-0518-encapsulation.html
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic