Application Development and Automation Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

Protected method in Final Class

Former Member
0 Likes
619

Hi all

Can we have protected method in Final class ?

If so how is it possible ?

Vicky

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
480

Hello

we cannot have protected method in final class.

Final class is used to prevent unwanted specialization by subclasses,

and hence it does not make any sense to have a protected method here more over,

it does not allow to do so.

Subin

2 REPLIES 2
Read only

Former Member
0 Likes
480

Final classes cannot have subclasses and hence no need of protected methods.

No comments on possibility.

Check this link from SAP help to know more :

http://help.sap.com/saphelp_nw70/helpdata/en/dd/4049c40f4611d3b9380000e8353423/content.htm

Hope this helps you.

Edited by: Harsh Bhalla on Dec 19, 2009 3:35 PM

Read only

Former Member
0 Likes
481

Hello

we cannot have protected method in final class.

Final class is used to prevent unwanted specialization by subclasses,

and hence it does not make any sense to have a protected method here more over,

it does not allow to do so.

Subin