How can we main a Class as base class,i.e not inherited
further?{please Dont tell using Sealed class,any other way}
Answer Posted / jay
final is an identifier valid in java, c# has sealed.
while its true that marking base CTOR as private makes
deriving from that class impossible, you SHOULD use sealed
for that purpose.
Reason is that "sealed" allows for some neat compiler
optimization.
| Is This Answer Correct ? | 1 Yes | 2 No |
Post New Answer View All Answers
What is the lock statement in c#?
What is the difference between returning iqueryable vs ienumerable?
How do you name a variable in c#?
Explain how many types of exception handlers are there in .net?
What does get set mean in c#?
How can I produce an assembly?
What is throw in c#?
Can you describe iuknown interface in short?
Is overriding of a function possible in the same class?
What is difference between singleton and static class in c#?
What is the use of 0 in c#?
How do you pronounce c#?
What are the drawbacks of extending an interface as opposed to extending a class?
Is an interface a type c#?
What is the difference between Java and .NET garbage collectors?