1answer.
Ask question
Login Signup
Ask question
All categories
  • English
  • Mathematics
  • Social Studies
  • Business
  • History
  • Health
  • Geography
  • Biology
  • Physics
  • Chemistry
  • Computers and Technology
  • Arts
  • World Languages
  • Spanish
  • French
  • German
  • Advanced Placement (AP)
  • SAT
  • Medicine
  • Law
  • Engineering
nevsk [136]
3 years ago
14

Data hiding, which means that critical data stored inside the object is protected from code outside the object, is accomplished

in Java by: __________
Computers and Technology
2 answers:
Klio2033 [76]3 years ago
4 0

Answer:

using the private access specifier on the class fields.

Explanation:

We can protect the data stored inside the object from the code outside in java by using the private access specifier on the class fields.

If the any class field is declared private it is not accessible to the objects outside that class.Private member are also not inherited in inheritance.

oee [108]3 years ago
4 0

<em>using the private access specifier on the class methods  </em>

<h2>Further explanation </h2>

Java is an OOP (Object Oriented Programming) paradigm programming language that can be run on computers with 32-bit or 64-bit systems. One software that operates the Java programming language is NetBeans IDE 7.2.

Private is the code that matches the name, this access is private. in other words, data and methods can only be accessed by the class they have.

Protected is an access code that makes a data or method that is defined with this level of access can be accessed by classes that have it only and also classes that include having descendants or Encapsulation data

Private Access

<em>public class StudentRecord </em>

<em>{ </em>

<em>         // basic access to variables </em>

<em>         private int name; </em>

<em> </em>

<em>          // basic access to the method </em>

<em>          private String getName () { </em>

<em>                      return name; </em>

<em>           } </em>

<em>} </em>

<em> </em>

In the example above, the variable name and the method getName () can only be accessed by the internal methods of the class.

Protected Access

<em>public class StudentRecord </em>

<em>{ </em>

<em>         // access to variables </em>

<em>         protected int name; </em>

<em> </em>

<em>          // basic access to the method </em>

<em>          protected String getName () { </em>

<em>                      return name; </em>

<em>           } </em>

<em>} </em>

In the example above, the variable name and the getName () method can only be accessed by internal class methods and subclasses of the StudentRecord class.

Learn More

private protected in Javascript brainly.com/question/13133829

method and class in javascript brainly.com/question/13148975

Details

Class: High School

Subject: Computers and Technology

Keywords: javascript, private access, protected

You might be interested in
How do news organizations primarily create revenue?
Tamiku [17]
D. through customer subscriptions
6 0
3 years ago
Read 2 more answers
Hi um... i just wanna say hi :P
trasher [3.6K]
Lol Heyy , how are you
4 0
3 years ago
Read 2 more answers
For computer forensics, ____________ is the task of collecting digital evidence from electronic media.
Zanzabum

For computer forensics, <u>data acquisition</u> is the task of collecting digital evidence from electronic media.

<h3>What is data acquisition?</h3>

Data acquisition is the process of gathering digital evidence from electronic media for computer forensics. Static acquisitions and live acquisitions are the two different categories of data acquisition.

You learn how to carry out static acquisitions from digital material in this chapter. It is the process of digitalization of data from the world.

Thus, <u>data acquisition</u> is the task of collecting digital evidence from electronic media.

To learn more about data acquisition, refer to the link:

brainly.com/question/28233320

#SPJ4

7 0
2 years ago
Write a program to demonstrate circular linked list with operations using pointers – insert
BabaBlast [244]

A program to demonstrate circular linked list with operations using pointers is:

struct Node *addToEmpty(struct Node *last, int data)

{

   // This function is only for empty list

   if (last != NULL)

     return last;

 

   // Creating a node dynamically.

   struct Node *temp =

         (struct Node*)malloc(sizeof(struct Node));

 

   // Assigning the data.

   temp -> data = data;

   last = temp;

   // Note : list was empty. We link single node

   // to itself.

   temp -> next = last;

 

   return last;

}

<h3>What is a Circular Linked List?</h3>

This refers to the type of linked list in which the first and the last nodes are also joined together other to form a circle

Read more about circular linked list here:

brainly.com/question/12974434

#SPJ1

5 0
2 years ago
In 1839, Talbot released the paper-based process which he called _ to the public.
vlabodo [156]

Answer:

I'm pretty sure it's photogenic drawing.

7 0
3 years ago
Other questions:
  • How do smart watches affect the business and its position in the global marketplace?
    12·2 answers
  • When using a template to compose a memorandum which key on the keyboard moves the cursor to the next field
    15·1 answer
  • Hacker is a person who illegally breaks into a system or network without any authorization to destroy, steal sensitive data or t
    14·1 answer
  • The calls radioed to patrol officers, or assignments given to police patrol units by 911 dispatchers, reveal the types of proble
    9·1 answer
  • which telecommunications service allows internet and telephone service to work over the same phone line
    13·1 answer
  • A local cinema allows customer to make a movie ticket reservation. A customer can be
    6·1 answer
  • On the Format tab, which group allows you to select a different font for a chart?
    7·2 answers
  • when I turn on my pc using a graphics card, it does give video, and everything is normal, but when I try to turn on my pc with t
    8·1 answer
  • Lab 8-1: Working with Boot Loader and Runlevels what is the root password
    9·1 answer
  • Explain with examples the roles of system software and application software?<br>​
    6·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!