[Quote=引用 4 楼 lightnut 的回复:]
template <
class Key,
class Type,
class Traits = less <Key>,
class Allocator=allocator <pair <const Key, Type> >
>
class map
Parameters
Key
The key data type to be stored in the map.
Type
The element data type to be stored in the map.
Traits
The type that provides a function object that can compare two element values as sort keys to determine the…
[/Quote]
MSDN上有
LZ去看看吧
template <
class Key,
class Type,
class Traits = less<Key>,
class Allocator=allocator<pair <const Key, Type> >
>
class map
Parameters
Key
The key data type to be stored in the map.
Type
The element data type to be stored in the map.
Traits
The type that provides a function object that can compare two element values as sort keys to determine their relative order in the map. This argument is optional and the binary predicate less<Key> is the default value.
Allocator
The type that represents the stored allocator object that encapsulates details about the map's allocation and deallocation of memory. This argument is optional and the default value is allocator<pair <const Key, Type> >.