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...


Y go for Interface? What is use of interface?

Answers were Sorted based on User's Feedback



Y go for Interface? What is use of interface?..

Answer / purushotham .tella

An Interface is a collection of semantically related
abstract members.Used To Support Multiple Inheritance

Is This Answer Correct ?    6 Yes 0 No

Y go for Interface? What is use of interface?..

Answer / venkat2050

interfaces is in concept of late binding which happen at
runtime which a part in OOPs concept
the interface has indexes of abstact
it should in public

Is This Answer Correct ?    4 Yes 2 No

Y go for Interface? What is use of interface?..

Answer / kiran

We will go for an interface when we want to implement a
specific behaviour.

ex:
1.My class x implements IDisposable interface to handle
cleaup operation. I have to implement that behaviour by
implementing the method interface method Dispose()
explicitly in my code.

class x:IDisposable
{}
2.My class y implements IComparable interface to implement
sorting between a list of objects created of type y. Here I
have to implement CompareTo method.

Is This Answer Correct ?    3 Yes 1 No

Post New Answer

More C Sharp Interview Questions

Can a class have multiple constructors c#?

0 Answers  


who is a protected class-level variable available to?

0 Answers   Siebel Systems,


i want o/p 011242110 in c# code.

0 Answers   TCS,


Can a class have more than 1 destructor?

0 Answers  


In which way you can convert a value-type to a reference-type?

0 Answers   Siebel,


Are all methods virtual in c#?

0 Answers  


Why do we need interfaces?

2 Answers   HCL,


What is xslt in c#?

0 Answers  


What is difference between for and foreach in c#?

0 Answers  


Is boxing an implicit conversion?

0 Answers  


Can you prevent your class from being inherited and becoming a base class for some other classes?

5 Answers  


Can a class or a struct have multiple constructors?

0 Answers  


Categories