Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

What is true about the protected keyword in terms of inheritance? Group of answer choices Protected members of a class have extra security built in

What is true about the protected keyword in terms of inheritance?
Group of answer choices
Protected members of a class have extra security built in via the compiler.
If you don't use protected, you have to rely on the public interface of the parent class to access/use parent functionality
Protected items are accessible within the scope of child classes but inaccessible outside to outside scope.
Protected members are inaccessible in child classes, we use private to make them accessible.
Shockingly ... protected properties and methods are accessible within the scope of anything that shares the package of the class.
This is actually true ... free point ... I forgot to mention this in lecture because I often don't use packages in my sample code for the sake of time. This is a Java feature.

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image_2

Step: 3

blur-text-image_3

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Database Systems Introduction To Databases And Data Warehouses

Authors: Nenad Jukic, Susan Vrbsky, Svetlozar Nestorov

1st Edition

1943153191, 978-1943153190

Students also viewed these Databases questions

Question

What are the steps that the EEOC uses once a charge is filed?

Answered: 1 week ago