02 February 2006

OOP: Encapsulation (Definitions)

"It is a simple, yet reasonable effective, system-building tool. It allows suppliers to present cleanly specified interfaces around the services they provide. A consumer has full visibility to the procedures offered by an object, and no visibility to its data. From a consumer's point of view, and object is a seamless capsule that offers a number of services, with no visibility as to how these services are implemented [...] technical term for this is encapsulation." (Brad J Cox, "Object Oriented Programming: An Evolutionary Approach", 1986)

A software development technique that consists of isolating a system function or a set of data and operations on those data within a module and providing precise specifications for the module. (IEEE," IEEE Standard Glossary of Software Engineering Terminology", 1990)

"The concept of encapsulation as used in an object-oriented context is not essentially different from its dictionary definition. It still refers to building a capsule, in the case a conceptual barrier, around some collection of things." (Rebecca Wirfs-Brock et al, "Designing Object-Oriented Software", 1990]

"Encapsulation or equivalently information hiding refers to the practice of including within an object everything it needs, and furthermore doing this in such a way that no other object need ever be aware of this internal structure." (Ian Graham, "Object-Oriented Methods", 1991]

"Data hiding is sometimes called encapsulation because the data and its code are put together in a package or 'capsule.'" (David N Smith, "Concepts of Object-Oriented Programming", 1991)

"Encapsulation is used as a generic term for techniques which realize data abstraction. Encapsulation therefore implies the provision of mechanisms to support both modularity and information hiding. There is therefore a one to one correspondence in this case between the technique of encapsulation and the principle of data abstraction." (Gordon Blair et al, "Object-Oriented Languages, Systems and Applications", 1991)

"Encapsulation (also information hiding) consists of separating the external aspects of an object which are accessible to other objects, from the internal implementation details of the object, which are hidden from other objects." (James Rumbaugh et al, "Object-Oriented Modeling and Design", 1991)

"[...] encapsulation - also known as information hiding - prevents clients from seeing its inside view, were the behavior of the abstraction is implemented." (Grady Booch, "Object-Oriented Design With Applications", 1991)

"We say that the changeable, hidden information becomes the secret of the module; also, according to a widely used jargon, we say that such information is encapsulated within the implementation." (Carlo Ghezzi et al, "Fundamentals of Software Engineering", 1991]

"As a process, encapsulation means the act of enclosing one or more items within a (physical or logical) container. Encapsulation, as an entity, refers to a package or an enclosure that holds (contains, encloses) one or more items. It is extremely important to note that nothing is said about 'the walls of the enclosure'. Specifically, they may be 'transparent', 'translucent', or even 'opaque'." Compare with information hiding, which implies invisibility." (Bill Pribyl & Steven Feuerstein, "Learning Oracle PL/SQL", 2001)

"Encasing information and behavior within an object so that its structure and implementation are hidden to other objects that interact with it." (Marcus Green & Bill Brogden, "Java 2 Programmer Exam Cram 2 (Exam CX-310-035)", 2003)

"A mechanism used to hide the data, internal structure, and implementation details of some element, such as an object or subsystem. All interaction with an object is through a public interface of operations." (Craig Larman, "Applying UML and Patterns", 2004)

"An object-oriented technique that may hide, or abstract, the inner workings of an object and expose only the relevant characteristics and operations on the object to other objects." (Bob Bryla, "Oracle Database Foundations", 2004)

"Restricting the visibility of members of a type so they are not visible to clients of the type when they shouldn’t be. This is a way of exposing only the abstraction supported by the type, while hiding implementation details, which prevents unwanted access to them from clients and keeps the abstraction exposed by the type consistent and minimal." (Dean Wampler & Alex Payne, "Programming Scala", 2009)

"In object-oriented design, the principle that it should be possible to refer to an object with behavior and not know anything about how that behavior is implemented." (David C Hay, "Data Model Patterns: A Metadata Map", 2010)

"Detail hiding. A class hides its internal details so the rest of the program doesn't need to understand how they work, just how to use them." (Rod Stephens, "Stephens' Visual Basic® Programming 24-Hour Trainer", 2011)

"(1) A language mechanism for restricting access to some of an object’s components. (2) A language construct that facilitates the bundling of data with methods (or other functions) operating on that data." (Craig S Mullins, "Database Administration: The Complete Guide to DBA Practices and Procedures", 2012)

"The veil of abstraction separating the interface from the implementation (whether enforced or not), which mandates that all access to an object’s state be through methods alone." (Jon Orwant et al, "Programming Perl" 4th Ed., 2012)

"A language feature that enforces information hiding; bundling data and actions so that the logical properties of data and actions are separated from the implementation details" (Nell Dale & John Lewis, "Computer Science Illuminated" 6th Ed., 2015)

"The bundling of data with the procedures that operate on that data, such that data may only be changed by those procedures - a technique for reducing program complexity." (O Sami Saydjari, "Engineering Trustworthy Systems", 2018)

"The object-oriented programming technique of limiting the exposure of variables and methods to simplify the API of a class or package. Using the private and protected keywords, a programmer can limit the exposure of internal ('black box') parts of a class. Encapsulation reduces bugs and promotes reusability and modularity of classes. This technique is also known as data hiding." (Daniel Leuck et al, "Learning Java" 5th Ed., 2020)

No comments:

Related Posts Plugin for WordPress, Blogger...

About Me

My photo
IT Professional with more than 24 years experience in IT in the area of full life-cycle of Web/Desktop/Database Applications Development, Software Engineering, Consultancy, Data Management, Data Quality, Data Migrations, Reporting, ERP implementations & support, Team/Project/IT Management, etc.