syntax for writing private method in a interface
Answers were Sorted based on User's Feedback
Answer / vanitha
An interface cannot have private methods. All the member
declarations inside interface are implicitly public.
| Is This Answer Correct ? | 20 Yes | 2 No |
Answer / pankaj
we cnt write private methods in an interface.as we have to
inherit that method its by default on public scope
| Is This Answer Correct ? | 12 Yes | 0 No |
Answer / anna
we can't have private methods in in interface.
by default all are public
| Is This Answer Correct ? | 9 Yes | 0 No |
Answer / jayamala
By default interface is public.Interface is accessed by
another class it should be public.so we cant write it as a
private.
| Is This Answer Correct ? | 6 Yes | 0 No |
Answer / sudhir kunnure
we create interface for inherite to classes, and Private
methods can only access within class not inherited class.so
you cannot create Private methods in Interface.
| Is This Answer Correct ? | 5 Yes | 0 No |
Answer / uma
By default all methods in the interface are not just
public !!!!! They are Public abstract.
Because methods of Interface will get override in the
Derived classes
| Is This Answer Correct ? | 2 Yes | 0 No |
Answer / manoj dhanik
we cannot change the access modifier of methods private inside interface....n all the methods of interface should be implement in derived class..so the methods should not private
| Is This Answer Correct ? | 1 Yes | 1 No |
What is null in database?
difference between managed code and unmanaged code ?
Can multiple catch blocks be executed?
What does ienumerable mean?
WHAT IS THE EXACT USE OF INTERFACE(DONT TELL USE FOR MULTIPLE INHERITANCE)
Hi Everyone, the design of the form disappear during writing codes for dataset and data grid. The error show in "line of assigning dataset". I don't know what's happen. If anyone know , please share of technical help from someone. Thanks, Horace Trever
What are the Different kinds of methods?
What is difference between int and int in c#?
6. If we assign a value in textbox on Page_UnLoad event, will it display?
What does the This window show in the debugger?
What is an assembly in .net?
What is use of private class in c#?
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)