What is indexers in C#

Answer Posted / abdul razack

n c# introduce new concept is Indexer. This is very useful for some situation. Let as discuss something about Indexer.
Indexer Concept is object act as an array.
Indexer an object to be indexed in the same way as an array.
Indexer modifier can be private, public, protected or internal.
The return type can be any valid C# types.
Indexers in C# must have at least one parameter. Else the compiler will generate a compilation error.

Is This Answer Correct ?    6 Yes 1 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What are the Types of values mode can hold session state in web.config

546


What's the difference between abstraction and encapsulation?

460


Is inheritance possible in c sharp?

626


What is difference between an Structure and Class?

565


What is the difference between dynamic type variables and object type variables in c#?

483






What is parallel foreach c#?

508


Why we use extension methods in c#?

466


What is the difference between constant and readonly in c#?

431


How do you mark a method obsolete?

576


What are the Types of compatabilities and explain them

516


What is a boolean c#?

473


What is the difference between delegates and events in c#?

421


What is private readonly in c#?

518


What is dataadapter c#?

478


What are the types of delegates in c#?

471