1 /* Copyright 2003-2008 Joaquin M Lopez Munoz.
2 * Distributed under the Boost Software License, Version 1.0.
3 * (See accompanying file LICENSE_1_0.txt or copy at
4 * http://www.boost.org/LICENSE_1_0.txt)
6 * See http://www.boost.org/libs/multi_index for library home page.
9 #ifndef BOOST_MULTI_INDEX_FWD_HPP
10 #define BOOST_MULTI_INDEX_FWD_HPP
12 #if defined(_MSC_VER)&&(_MSC_VER>=1200)
16 #include <boost/config.hpp> /* keep it first to prevent nasty warns in MSVC */
17 #include <boost/multi_index/identity.hpp>
18 #include <boost/multi_index/indexed_by.hpp>
19 #include <boost/multi_index/ordered_index_fwd.hpp>
24 namespace multi_index
{
26 /* Default value for IndexSpecifierList specifies a container
27 * equivalent to std::set<Value>.
32 typename IndexSpecifierList
=indexed_by
<ordered_unique
<identity
<Value
> > >,
33 typename Allocator
=std::allocator
<Value
> >
34 class multi_index_container
;
36 template<typename MultiIndexContainer
,int N
>
39 template<typename MultiIndexContainer
,typename Tag
>
42 template<typename MultiIndexContainer
,int N
>
43 struct nth_index_iterator
;
45 template<typename MultiIndexContainer
,int N
>
46 struct nth_index_const_iterator
;
48 template<typename MultiIndexContainer
,typename Tag
>
49 struct index_iterator
;
51 template<typename MultiIndexContainer
,typename Tag
>
52 struct index_const_iterator
;
54 /* get and project functions not fwd declared due to problems
55 * with dependent typenames
59 typename Value1
,typename IndexSpecifierList1
,typename Allocator1
,
60 typename Value2
,typename IndexSpecifierList2
,typename Allocator2
63 const multi_index_container
<Value1
,IndexSpecifierList1
,Allocator1
>& x
,
64 const multi_index_container
<Value2
,IndexSpecifierList2
,Allocator2
>& y
);
67 typename Value1
,typename IndexSpecifierList1
,typename Allocator1
,
68 typename Value2
,typename IndexSpecifierList2
,typename Allocator2
71 const multi_index_container
<Value1
,IndexSpecifierList1
,Allocator1
>& x
,
72 const multi_index_container
<Value2
,IndexSpecifierList2
,Allocator2
>& y
);
75 typename Value1
,typename IndexSpecifierList1
,typename Allocator1
,
76 typename Value2
,typename IndexSpecifierList2
,typename Allocator2
79 const multi_index_container
<Value1
,IndexSpecifierList1
,Allocator1
>& x
,
80 const multi_index_container
<Value2
,IndexSpecifierList2
,Allocator2
>& y
);
83 typename Value1
,typename IndexSpecifierList1
,typename Allocator1
,
84 typename Value2
,typename IndexSpecifierList2
,typename Allocator2
87 const multi_index_container
<Value1
,IndexSpecifierList1
,Allocator1
>& x
,
88 const multi_index_container
<Value2
,IndexSpecifierList2
,Allocator2
>& y
);
91 typename Value1
,typename IndexSpecifierList1
,typename Allocator1
,
92 typename Value2
,typename IndexSpecifierList2
,typename Allocator2
95 const multi_index_container
<Value1
,IndexSpecifierList1
,Allocator1
>& x
,
96 const multi_index_container
<Value2
,IndexSpecifierList2
,Allocator2
>& y
);
99 typename Value1
,typename IndexSpecifierList1
,typename Allocator1
,
100 typename Value2
,typename IndexSpecifierList2
,typename Allocator2
103 const multi_index_container
<Value1
,IndexSpecifierList1
,Allocator1
>& x
,
104 const multi_index_container
<Value2
,IndexSpecifierList2
,Allocator2
>& y
);
106 template<typename Value
,typename IndexSpecifierList
,typename Allocator
>
108 multi_index_container
<Value
,IndexSpecifierList
,Allocator
>& x
,
109 multi_index_container
<Value
,IndexSpecifierList
,Allocator
>& y
);
111 } /* namespace multi_index */
113 /* multi_index_container, being the main type of this library, is promoted to
117 using multi_index::multi_index_container
;
119 } /* namespace boost */