If u declare two interfaces withsame methodnmae .prototype
how can u call the particular method from class?

Answers were Sorted based on User's Feedback



If u declare two interfaces withsame methodnmae .prototype how can u call the particular method fro..

Answer / umesh

Using Interface.Methodname

Is This Answer Correct ?    4 Yes 0 No

If u declare two interfaces withsame methodnmae .prototype how can u call the particular method fro..

Answer / diana cheriyan

Suppose IntSample1 and IntSample2 are interface,then We call
method of IntSample1 by IntSample1.Methodname

Is This Answer Correct ?    4 Yes 1 No

If u declare two interfaces withsame methodnmae .prototype how can u call the particular method fro..

Answer / n.v.s prasad

By using explicit interface declaration which is nothing
but (Interfacename.Methodname) but the problem is method
available to interface not for class(if you careate
instance of your class we are not able to access method
which we implemented above in our class, so method is
availble to interface only)

Note:If you want to acess method by instance of your class
we need to cast our instance to 'interface'
((instance)interfacename).methodname--->Possible
instance.methodname ---->Not possible

Is This Answer Correct ?    2 Yes 0 No

If u declare two interfaces withsame methodnmae .prototype how can u call the particular method fro..

Answer / srinivas.r

we need to implement methods of interfaces explictly i.e
interfaceName.methodName

Is This Answer Correct ?    2 Yes 0 No

Post New Answer

More C Sharp Interview Questions

What is difference between tostring() vs convert.tostring() vs (string) cast

0 Answers  


How do I automate my desktop application?

0 Answers  


What is difference between class and abstract class in c#?

0 Answers  


When was c# created?

0 Answers  


What is xamarin used for?

0 Answers  






C# is case sensitive, what is mean by case sensitive

3 Answers  


What is the Difference between imperative and interrogative code?

2 Answers   Wipro,


What is the difference between User controls and Custom Controls?

0 Answers   Accenture,


which access modifier we can declare the abstract class?

5 Answers   IBM,


What are immutable types in c#?

0 Answers  


C# provides a default constructor for me. I write a constructor that takes a string as a parameter, but want to keep the no parameter one. How many constructors should I write?

3 Answers   Visual Soft,


How do you sort a list in c#?

0 Answers  


Categories