Wintellect.PowerCollections Namespace
Algorithms Class
GhostDoc Pro Sample Help File

OrderedDictionary<(Of <(<'TKey, TValue>)>)>..::..TryGetValue Method

Determines if this dictionary contains a key equal to key. If so, the value associated with that key is returned through the value parameter.

Namespace:  Wintellect.PowerCollections
Assembly:  PowerCollections (in PowerCollections.dll)

Syntax


public bool TryGetValue(
	TKey key,
	out TValue value
)
Public Function TryGetValue ( _
	key As TKey, _
	<OutAttribute> ByRef value As TValue _
) As Boolean
public:
bool^ TryGetValue(
	TKey key, 
	[OutAttribute] TValue% value
)

Parameters

key
Type: TKey
The key to search for.
value
Type: TValue%
Returns the value associated with key, if true was returned.

Return Value

True if the dictionary contains key. False if the dictionary does not contain key.

Remarks


TryGetValue takes time O(log N), where N is the number of entries in the dictionary.