Tech Tutorials Database
GeekArticles Microsoft C#

Indexers In C#

Category: C#
Comments (0)

By Rajesh C# introduces a new concept known as Indexers which are used for treating an object as an array. The indexers are usually known as smart arrays in C# community. Defining a C# indexer is much like defining properties. We can say that an indexer is a member that enables an object to be indexed in the same way as an array. <modifier> <return type> this [argument list] { get { // Get codes goes here } set { // Set codes goes here } } Where the modifier can be private, public,...n


Sponsored Links

Read Next: A C# Class