Compartir a través de


hash_set::key_type

A type that describes an object stored as an element of a hash_set in its capacity as sort key.

typedef Key key_type;

Remarks

key_type is a synonym for the template parameter Key.

For more information on Key, see the Remarks section of the hash_set Class topic.

Note that both key_type and value_type are synonyms for the template parameter Key. Both types are provided for the hash_set and hash_multiset classes, where they are identical, for compatibility with the hash_map and hash_multimap classes, where they are distinct.

In Visual C++ .NET 2003, members of the <hash_map> and <hash_set> header files are no longer in the std namespace, but rather have been moved into the stdext namespace. See The stdext Namespace for more information.

Example

See the example for value_type for an example of how to declare and use key_type.

Requirements

Header: <hash_set>

Namespace: stdext

See Also

Reference

hash_set Class

Standard Template Library

Other Resources

hash_set Members