What are Sealed Classes in C#?

Answer Posted / kanchan kora

A class which restricts inheritance for security region is
called Sealed class.
Sealed class is the last class in hierarchy.
Sealed class can be a derived class but can't be a base class.
To access the members of sealed class we should create the
instance object.

Advantages of sealed class is it restrict the third party
vendor for developing new software by inheriting from our logic.

Is This Answer Correct ?    50 Yes 9 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is yield break in c#?

509


What is difference between list and ilist in c#?

470


Explain how obfuscator works in .net

549


Okay, so an int is a value type, and a class is a reference type. How can int be derived from object?

550


What are the variables in c#?

502






Why dictionary is used in c#?

544


Difference between type constructor and instance constructor? What is static constructor, when it will be fired? And what is its use?

546


Perfect Example Of While And Do-While Loop In C#.Net ?

570


What is the function of the not null constraint?

495


How to find type of variable?

544


What is Reflection in .NET? Namespace? How will you load an assembly which is not referenced by current assembly?

529


What language is c# similar to?

485


How to implement singleton design pattern in c#?

474


Explain the importance and use of each, version, culture and publickeytoken for an assembly.

530


What is out in c#?

516