Sdílet prostřednictvím


hash_map::hasher (STL/CLR)

Hash delegáta pro klíč.

    Microsoft::VisualC::StlClr::UnaryDelegate<GKey, int>
        hasher;

Poznámky

Typ popisuje delegát, který převede hodnoty klíče na celé.

Příklad

// cliext_hash_map_hasher.cpp 
// compile with: /clr 
#include <cliext/hash_map> 
 
typedef cliext::hash_map<wchar_t, int> Myhash_map; 
int main() 
    { 
    Myhash_map c1; 
    Myhash_map::hasher^ myhash = c1.hash_delegate(); 
 
    System::Console::WriteLine("hash(L'a') = {0}", myhash(L'a')); 
    System::Console::WriteLine("hash(L'b') = {0}", myhash(L'b')); 
    return (0); 
    } 
 
  

Požadavky

Záhlaví:<cliext/hash_map>

Obor názvů: cliext

Viz také

Referenční dokumentace

hash_map (STL/CLR)

hash_map::hash_delegate (STL/CLR)