Language
Edit

IDataSource.GetCollectionCount(String) Method

Definition

If a key path represents a collection, return the number of items in that collection.

public int GetCollectionCount(string resolvedKeyPath);
abstract member GetCollectionCount : string -> int
Public Function GetCollectionCount (resolvedKeyPath As String) As Integer

Parameters

resolvedKeyPath
String

The key path of data to be checked.

Returns

integer size of the collection. An empty collection is valid.

Remarks

This can be used by a data consumer to pre-allocate resources to receive the collection, and also to determine the valid index range of 0 to N-1 when using GetNthCollectionKayPathAt() to retrieve entries in the collection.

Applies to