 | RouletteDictionary<TKey, TValue>.GetRandomKeyAndValue Method (Func<TValue, Boolean>) |
Gets a random key-value pair from the dictionary whose value satisfies a condition.
Namespace:
Scaleout.Collections
Assembly:
Scaleout.Collections (in Scaleout.Collections.dll) Version: 1.0.3.0 (1.0.3.0)
Syntaxpublic KeyValuePair<TKey, TValue> GetRandomKeyAndValue(
Func<TValue, bool> predicate
)
Parameters
- predicate
- Type: System.Func<TValue, Boolean>
A function to test elements for a condition.
Return Value
Type:
KeyValuePair<TKey,
TValue>A random key-value pair from the dictionary.
Exceptions
See Also