Boost C++ Libraries Boost.Bimap Home Libraries People FAQ More

PrevUpHomeNext

unordered_multiset_of Struct Template Reference

Set Type Specification. More...

#include <unordered_multiset_of.hpp>

Inheritance diagram for unordered_multiset_of:

Inheritance graph
Collaboration diagram for unordered_multiset_of:

Collaboration graph
List of all members.

Public Types

typedef HashFunctor hasher
 Hash Functor that takes value_type objects.
typedef EqualKey key_equal
 Functor that compare two value_type objects for equality.
typedef mpl::bool_< false > mutable_key
typedef KeyType value_type
 The type that will be stored in the container.

Detailed Description

template<class KeyType, class HashFunctor = hash< KeyType >, class EqualKey = std::equal_to< KeyType >>
struct boost::bimaps::unordered_multiset_of< KeyType, HashFunctor, EqualKey >

Set Type Specification.

This struct is used to specify an unordered_multiset specification. It is not a container, it is just a metaprogramming facility to express the type of a set. Generally, this specification will be used in other place to create a container. It has the same syntax that an tr1::unordered_multiset instantiation, except that the allocator cannot be specified. The rationale behind this difference is that the allocator is not part of the unordered_multiset type specification, rather it is a container configuration parameter. The first parameter is the type of the objects in the set, the second one is a Hash Functor that takes objects of this type, and the third one is a Functor that compares them for equality. Bimap binding metafunctions can be used with this class in the following way:

using namespace support;

BOOST_STATIC_ASSERT( is_set_type_of< unordered_multiset_of<Type> >::value );

BOOST_STATIC_ASSERT
(
     is_same
     <
        compute_index_type
        <
            unordered_multiset_of<Type,HashFunctor,EqualKey>,
            KeyExtractor,
            Tag

        >::type
        ,
        hashed_nonunique< tag<Tag>, KeyExtractor, HashFunctor, EqualKey >

    >::value
);

typedef bimap
<
    unordered_multiset_of<Type>, RightKeyType

> bimap_with_left_type_as_unordered_multiset;

BOOST_STATIC_ASSERT
(
    is_same
    <
        compute_map_view_type
        <
            member_at::left,
            bimap_with_left_type_as_unordered_multiset

        >::type,

        unordered_multimap_view
        <
            member_at::left,
            bimap_with_left_type_as_unordered_multiset
        >

    >::value
);

See also unordered_multiset_of_relation.

Definition at line 118 of file unordered_multiset_of.hpp.


The documentation for this struct was generated from the following file:
Copyright 2006 Matias Capeletto

PrevUpHomeNext