ObjectCache.GetCount(String) 方法

定义

在派生类中重写时,获取缓存中的缓存项总数。When overridden in a derived class, gets the total number of cache entries in the cache.

public abstract long GetCount (string regionName = default);
abstract member GetCount : string -> int64
Public MustOverride Function GetCount (Optional regionName As String = Nothing) As Long

参数

regionName
String

可选。Optional. 缓存中应计算其缓存项数的命名区域(如果实现了区域)。A named region in the cache for which the cache entry count should be computed, if regions are implemented. 可选参数的默认值为 nullThe default value for the optional parameter is null.

返回

Int64

缓存中的缓存项数。The number of cache entries in the cache. 如果 regionName 不为 null,则计数指示指定的缓存区域中的项数。If regionName is not null, the count indicates the number of entries that are in the specified cache region.

适用于