can we create an empty interface with no definitions? If
so, how it should be called in the class?
Answer Posted / mohit bhandari
Yes we can create an empty interface.Empty interface is
called a marker interface.These interfaces are generally
used as way of identifying a group of types. If this
identification will occur at runtime, the correct way to
accomplish this is to use a custom attribute. Use the
presence or absence of the attribute, or the attribute's
properties, to identify the target types.As there is no
method in marker interface,So we don't need to call it.
| Is This Answer Correct ? | 7 Yes | 1 No |
Post New Answer View All Answers
What is clr in c#?
How big is a float?
How do you prevent a class from being inherited?
What is the use of the dispose method in C# ?
What is uint c#?
When should I use static in C#?
Why do we use reflection in c#?
Explain the functionalities of satellite assembly?
List down the differences between “dispose” and “finalize” methods in c#.
State whether it is true to test a Web service you must create a windows application or Web application to consume this service or not?
What does || mean in programming?
What is a scope in c#?
List down the differences between public, static and void keywords?
When would you use generics in your code c#?
What is fcl in c#?