How should you call the Glass class implementation of the breakO method?

You have a class named Glass that inherits from a base class named Window. The Window
class includes a protected method named break().
How should you call the Glass class implementation of the breakO method?

You have a class named Glass that inherits from a base class named Window. The Window
class includes a protected method named break().
How should you call the Glass class implementation of the breakO method?

A.
Glass.break()

B.
Window.break()

C.
Me.break()

D.
MyBase.break()



Leave a Reply 3

Your email address will not be published. Required fields are marked *


DB7

DB7

Unclear questions???
Depends where called.
From within Glass class = MyBase.Break
From instance of Glass class = cGlass.Break (technically it wouldn’t be Glass.Break as instance would not be named same as class, otherwise that’s the shared/static syntax)