An #Indexer is a special type of property that allows a class or structure to be accessed the same way as array for its internal #collection.
The indexed value can be set or retrieved without explicitly specifying a type or instance member.
To define an Indexer we need to:
- Declare an array to store the data elements
- Define the indexer to allow client code to use the [ ] notation
The indexers are usually known as smart arrays in C#....
#dotnet #csharp #dotnetcore #array #class #object #store #data #dataelement #programming #dev #web #dotnethow #ervistrupja