MarkLogic XCC/.Net Library

ResultSequence.ResultItemAt Method 

Returns the ResultItem from this ResultSequence, if possible, at the given positional index. Accessing ResultItems randomly has restrictions if Cached is true.

For streaming ResultSequences, if index is equal to the current position, then the current ResultItem is returned. If index is less than the current position, then an exception is thrown. If index is greater than the current position, then items in the sequence are read and discarded until the requested position is achieved. If the requested item is found, it is returned. If the end of the sequence is encountered while trying to seek to the requested position, an exception is thrown.

[Visual Basic]
Function ResultItemAt( _
   ByVal index As Integer _
) As ResultItem
[C#]
ResultItem ResultItemAt(
   int index
);

Parameters

index
The position (zero-based) of the ResultItem to return.

Return Value

The ResultItem at the given index.

See Also

ResultSequence Interface | Marklogic.Xcc Namespace