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

PrevUpHomeNext

generate_view_binder.hpp

Go to the documentation of this file.
00001 // Boost.Bimap
00002 //
00003 // Copyright (c) 2006-2007 Matias Capeletto
00004 //
00005 // Distributed under the Boost Software License, Version 1.0.
00006 // (See accompanying file LICENSE_1_0.txt or copy at
00007 // http://www.boost.org/LICENSE_1_0.txt)
00008 
00009 /// \file detail/generate_view_binder.hpp
00010 /// \brief Define macros to help building the set type of definitions
00011 
00012 #ifndef BOOST_BIMAP_DETAIL_GENERATE_VIEW_BINDER_HPP
00013 #define BOOST_BIMAP_DETAIL_GENERATE_VIEW_BINDER_HPP
00014 
00015 #if defined(_MSC_VER) && (_MSC_VER>=1200)
00016 #pragma once
00017 #endif
00018 
00019 #include <boost/config.hpp>
00020 
00021 #include <boost/multi_index/tag.hpp>
00022 
00023 /*===========================================================================*/
00024 #define BOOST_BIMAP_GENERATE_MAP_VIEW_BINDER(                                 \
00025                                                                               \
00026     MAP_VIEW_TYPE                                                             \
00027                                                                               \
00028 )                                                                             \
00029                                                                               \
00030 template< class Tag, class BimapType >                                        \
00031 struct map_view_bind                                                          \
00032 {                                                                             \
00033     typedef MAP_VIEW_TYPE                                                     \
00034     <                                                                         \
00035         Tag,                                                                  \
00036         BimapType                                                             \
00037                                                                               \
00038     > type;                                                                   \
00039 };
00040 /*===========================================================================*/
00041 
00042 
00043 /*===========================================================================*/
00044 #define BOOST_BIMAP_GENERATE_SET_VIEW_BINDER(                                 \
00045                                                                               \
00046     SET_VIEW_TYPE                                                             \
00047                                                                               \
00048 )                                                                             \
00049                                                                               \
00050 template< class IndexType >                                                   \
00051 struct set_view_bind                                                          \
00052 {                                                                             \
00053     typedef SET_VIEW_TYPE<IndexType> type;                                    \
00054 };
00055 /*===========================================================================*/
00056 
00057 
00058 #endif // BOOST_BIMAP_DETAIL_GENERATE_VIEW_BINDER_HPP
Copyright 2006 Matias Capeletto

PrevUpHomeNext