[HD Pg 0, Sec. 4.4.2 - scope-and-visibility]

Help and support on OCA OCP Java Programmer Certification Questions
1Z0-808, 1Z0-809, 1Z0-815, 1Z0-816, 1Z0-817

Moderator: admin

Post Reply
nk2164
Posts: 21
Joined: Mon Sep 30, 2019 9:48 pm
Contact:

[HD Pg 0, Sec. 4.4.2 - scope-and-visibility]

Post by nk2164 »

In this chapter , you refer to the terms shadowing and hiding. You said they have different meaning in Java . I understand your explanation of shadowing (a variable in a method shadows a variable with the same name declared at class level).

What about hiding ? can you please give an example ? . Thank you.

admin
Site Admin
Posts: 10388
Joined: Fri Sep 10, 2010 9:26 pm
Contact:

Re: [HD Pg 0, Sec. 4.4.2 - scope-and-visibility]

Post by admin »

Explained in detail with an example in Section 12.6 Distinguish overloading, overriding, and hiding.

nk2164
Posts: 21
Joined: Mon Sep 30, 2019 9:48 pm
Contact:

Re: [HD Pg 0, Sec. 4.4.2 - scope-and-visibility]

Post by nk2164 »

ok, thank you.

Post Reply

Who is online

Users browsing this forum: No registered users and 20 guests