+10

What is data hiding?

c++

9/19/2019 2:20:00 PM

Rajeshwari Dadaji Ahire

15 Answers

New Answer

+12

It's one of the best features of object oriented programming. it's like restricting access of data members to a the entire program so that the hidden data can only be accessed by the class member functions.

+7

+5

 data hiding is a programming concept which protects the data from direct modification by other parts of the program. The feature of information hiding is applied using Class in most of the programming languages.

+5

Polymorphism uses data hiding when a sub class has the same field name as its superclass, if you create a object of sub class that's referenced by its parent class then the field in parent in used, if you create an object of sub class and is referenced by that sub class then the field in subclass is used and parent class field is hidden.

+4

Class dog { private: void secretBark() { std::cout<<"BJORK"; } } What you've just seen is called "the secret bark"

+4

It is done by the use of the class and the class specifiers -private and public.Where the private is used to hide the data from other classes and functions

+4

Data hiding is a software development technique specifically used in object-oriented programming (OOP) to hide internal object details (data members). Data hiding ensures exclusive data access to class members and protects object integrity by preventing unintended or intended changes.

+3

Same as abstraction,hiding relevant data from the user

+3

its done by concept of encapsulation

+2

Basically it's when you got your things well encapsulated

+2

Making fields of a class private and only accessible via public getter/setter methods.

+1

I don't know about you but I've seen Data has had some shifty eyes lately. I know theyre hiding something...

+1

guys, I'm a 12 class boy, ENTIRELY new to coding and programming

+1

Data hinding is achieved by encapsulation.it's like restricting access of data members to a the entire program so that the hidden data can only be accessed by the class member functions.

-1

ohlala