Method IndexOf
IndexOf(BsonValue)
Gets the index of a value in the array.
public virtual int IndexOf(BsonValue value)
Parameters
value
BsonValueThe value to search for.
Returns
- int
The zero based index of the value (or -1 if not found).
IndexOf(BsonValue, int)
Gets the index of a value in the array.
public virtual int IndexOf(BsonValue value, int index)
Parameters
value
BsonValueThe value to search for.
index
intThe zero based index at which to start the search.
Returns
- int
The zero based index of the value (or -1 if not found).
IndexOf(BsonValue, int, int)
Gets the index of a value in the array.
public virtual int IndexOf(BsonValue value, int index, int count)
Parameters
value
BsonValueThe value to search for.
index
intThe zero based index at which to start the search.
count
intThe number of elements to search.
Returns
- int
The zero based index of the value (or -1 if not found).