GeekInterview.com
   Home |  Tech FAQ  |   Interview Questions |  Placement Papers |  Tech Articles |  Learn |  Freelance Projects |  Online Testing |  Geeks Talk |  Job Postings |  Knowledge Base | Site Search |  Add/Ask Question

  GeekInterview.com  >  Interview Questions  >  J2EE  >  Core Java

 Print  |  
Question:  how and when to prevent inheritance?



January 01, 2006 05:06:19 #1
 vemodhara J2EE Expert  Member Since: September 2005    Total Comments: 10 

RE: how and when to prevent inheritance?
 
how to preventing inheritance:by a class declared as final then that calss cannot be inheritedwhen preventing the inheritance:suppose iy ur class no need to reused then only u can declare final .
     

 

Back To Question