what is the use of final method
Answers were Sorted based on User's Feedback
First of all sealed in c# is equivalent to final in java.
Sealed is used to stop further overriding an abstract method.
E.g:
public abstract class A
{
public abstract void print();
}
public class B:A
{
public sealed override void print()
{
Console.WriteLine("First override");
}
}
public class C:B
{
public override void print() //This will give compilation error.
{
Console.WriteLine("Second override");
}
}
| Is This Answer Correct ? | 0 Yes | 0 No |
How we can add the CSS in ASP.Net MVC?
what are background threads? give ex?
Explain .Net Framework? Why we use it?
What is the meaning of unobtrusive javascript? Explain us by any practical example.
How to use Jquery Plugins in ASP.Net MVC validation?
How do you assign a value to a complex number 7 how has exception hand changed in .net framework 4.0?
Explain the use of Inversion of control (IOC)?
What is objectset? : Entity framework
How the framework differentiate between 2 version dlls? eg Version 2.0 and 2.1 dlls are there. both are referred in the code.but we are using only name of that dll not the version number. in run time how the framework know which dll has to be referred?
Can we look at the IL for an assembly?
What is route config?
mention what is code first approach and model first approach in entity framework?