ConcurrentDictionary<TKey,TValue>.TryGetAlternateLookup<TAlternateKey> Método
Definição
Importante
Algumas informações se referem a produtos de pré-lançamento que podem ser substancialmente modificados antes do lançamento. A Microsoft não oferece garantias, expressas ou implícitas, das informações aqui fornecidas.
Obtém uma instância de um tipo que pode ser usado para executar operações em um ConcurrentDictionary<TKey,TValue> uso de uma TAlternateKey chave em vez de uma TKey.
public:
generic <typename TAlternateKey>
bool TryGetAlternateLookup([Runtime::InteropServices::Out] System::Collections::Concurrent::ConcurrentDictionary<TKey, TValue>::AlternateLookup<TAlternateKey> % lookup);
public bool TryGetAlternateLookup<TAlternateKey>(out System.Collections.Concurrent.ConcurrentDictionary<TKey,TValue>.AlternateLookup<TAlternateKey> lookup) where TAlternateKey : allows ref struct;
member this.TryGetAlternateLookup : AlternateLookup -> bool
Public Function TryGetAlternateLookup(Of TAlternateKey) (ByRef lookup As ConcurrentDictionary(Of TKey, TValue).AlternateLookup(Of TAlternateKey)) As Boolean
Parâmetros de tipo
- TAlternateKey
O tipo alternativo de uma chave para executar pesquisas.
Parâmetros
A instância de pesquisa criada quando o método retorna trueou uma instância padrão que não deve ser usada se o método retornar false.
Retornos
true se uma pesquisa puder ser criada; caso contrário, false.
Comentários
Essa instância deve estar usando um comparador que implemente IAlternateEqualityComparer<TAlternate,T> com TAlternateKey e TKey. Se não o fizer, o método retornará false.