IDataSource.GetCollectionCount(String) Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
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.