Data abstraction and encapsulation
The wrapping up of data and methods into a single unit (called class) is known as encapsulation. It is the most striking characteristics of a class. The data is not accessible to the outside world and only those methods that are wrapped in the class could access it. These methods give the interface among the object's data and the program. That insulation of the data from direct access through the program is known as data hiding. The Encapsulation makes it possible for objects to be treated like "black boxes" every performing a specific task without any concern for internal implementation.
Abstraction refers to the act of representing essential features without including the background details or explanations. A Class uses the concept of abstraction and is described as a list of abstract attributes like as size, weight and cost and techniques in which operated on these attributes. They encapsulate all the essential properties of the objects that are to be created.