what is the real use of interface in c#,other than that
multiple inheritance is not possible
Answers were Sorted based on User's Feedback
When creating a standalone project which can be
changed at will, use an interface in preference to an
abstract class; because, it offers more design flexibility.
Use an interface to design a polymorphic hierarchy
for value types.
Use an interface when an immutable contract is
really intended.
A well-designed interface defines a very specific
range of functionality. Split up interfaces that contain
unrelated functionality.
| Is This Answer Correct ? | 48 Yes | 14 No |
Answer / kalaimani
The interface contains only declaration of methods, no implementation. Because the interface is can be inherited by class and struct.
| Is This Answer Correct ? | 21 Yes | 9 No |
Answer / venkatesan
Interface is a contract which declares a method inside and
gives the implementation in different classes using
polymorphism. we cannot create a object to an interface but
we can create a reference for an interface.
| Is This Answer Correct ? | 4 Yes | 0 No |
Answer / siddu.
Interfaces are used to define common functionality among the
child classes or struts.
Interfaces can be used to implement some rules on the
derived classes or struts.
Interface are used to hold object of a class which derives
it in client machine in case of remoting.
| Is This Answer Correct ? | 7 Yes | 5 No |
Answer / ankita
In the phase of interfaces we can only declare methods. and
this method can contain its definition in the different
classes where we can define it.........
| Is This Answer Correct ? | 1 Yes | 6 No |
Answer / ravindarjobs
have a look at this link
http://msdn2.microsoft.com/en-us/library/3b5b8ezk.aspx
| Is This Answer Correct ? | 10 Yes | 17 No |
Answer / satyaprakash reddy
c#.net will not support multiple inheritence to overcome
these problems we use interfaces,
actually c# is faces some problems while go through the
garbage collection and interfaces are better according to
performance
| Is This Answer Correct ? | 21 Yes | 33 No |
Enlist the different types of classes in c#?
What is the purpose of ienumerable in c#?
What do you mean by synchronous and asynchronous operations?
What is a web service in c#?
In a stored procedure 4 select stmts there.If error comes in one select stmt will remaining normally executes?
Differentiate between the public and private ?
List the difference between interface and abstract class?
How to reverse each word in a string using c#?
What is hashtable in c# with example?
What is the difference between console application and windows application?
How do you serialize in c#?
What are Custom Control and User Control?
Visual Basic (800)
C Sharp (3816)
ASP.NET (3180)
VB.NET (461)
COM+ (79)
ADO.NET (717)
IIS (369)
MTS (11)
Crystal Reports (81)
BizTalk (89)
Dot Net (2435)
Exchange Server (362)
SharePoint (720)
WCF (340)
MS Office Microsoft (6963)
LINQ Language-Integrated Query (317)
WPF (371)
TypeScript (144)
Microsoft Related AllOther (311)