What is an indexer? example

Posted by Naga116 under C# on 8/18/2011 | Points: 10 | Views : 2039 | Status : [Member] | Replies : 1
Use of indexers in C#.net? can you please provide a good example regarding the indexer?

Nagaraju


Responses

Posted by: Nisar87 on: 8/18/2011 [Member] Starter | Points: 25

Up
0
Down
Indexer allow your class to be used just like an array. On the inside of a class, you manage a collection of values any way you want. These objects could be a finite set of class members, another array, or some complex data structure. Regardless of the internal implementation of the class, its data can be obtained consistently through the use of indexers.

here is the good example of indexer in c#
http://www.c-sharpcorner.com/UploadFile/senthurganesh/109172007050741AM/1.aspx

_______________________________________
Nisar Ahmad
http://www.dotnetobject.com/

Naga116, if this helps please login to Mark As Answer. | Alert Moderator

Login to post response