Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

is it possible to inherit a class but methods declared in
the class should not be inheritable i possible how?

Answer Posted / vishal

That's Correct.
Using private keyword in the method signature is a way of
preventing inheritance of that method in child class.

Please note that using "sealed" keyword in method signature
only prevents overriding of the method in child class, but
the method is still inheritable in the child class.

Is This Answer Correct ?    8 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

How to get the sum of last 3 items in a list using lambda expressions?

974


What is a thread? What is multithreading?

989


What is thread.sleep()?

955


What do you mean by object pooling?

1118


What is a deadlock lock?

974


What is an indexer in c#?

1023


What is action c#?

953


Can a static class contain non static members?

1040


What is assembly version series sequence?

1044


What is function and method in c#?

1046


What are bitwise logical operators?

946


Can hashset contain duplicates c#?

1006


1. Describe page life cycle?

2163


how to sort an array in c#

1067


What is difference between interface and abstraction?

943