29 #if defined(IteratorCirculatorTraits_RECURSES)
30 #error Recursive header files inclusion detected in IteratorCirculatorTraits.h
33 #define IteratorCirculatorTraits_RECURSES
35 #if !defined IteratorCirculatorTraits_h
37 #define IteratorCirculatorTraits_h
42 #include<boost/iterator/iterator_categories.hpp>
43 #include<boost/iterator/iterator_facade.hpp>
75 template <
typename IC>
99 template <
typename IC,
typename ICType>
106 template <
typename IC>
126 template <
typename IC,
bool flagHasNestedTypeCalledType = false>
133 template <
typename IC>
150 template <
typename IC>
168 template<
bool b = false>
189 template<
typename IC>
212 template <
typename C>
252 #if (((BOOST_VERSION /100000)==1) && ((BOOST_VERSION / 100 % 1000 )<57))
254 struct ToDGtalCategory<
boost::detail::iterator_category_with_traversal<std::input_iterator_tag,boost::forward_traversal_tag> > {
258 struct ToDGtalCategory<
boost::detail::iterator_category_with_traversal<std::input_iterator_tag,boost::bidirectional_traversal_tag> > {
259 typedef BidirectionalCategory
Category;
263 struct ToDGtalCategory<
boost::detail::iterator_category_with_traversal<std::input_iterator_tag,boost::random_access_traversal_tag> > {
264 typedef RandomAccessCategory
Category;
268 struct ToDGtalCategory<
boost::iterators::detail::iterator_category_with_traversal<std::input_iterator_tag,boost::forward_traversal_tag> > {
272 struct ToDGtalCategory<
boost::iterators::detail::iterator_category_with_traversal<std::input_iterator_tag,boost::bidirectional_traversal_tag> > {
277 struct ToDGtalCategory<
boost::iterators::detail::iterator_category_with_traversal<std::input_iterator_tag,boost::random_access_traversal_tag> > {
293 template <
typename IC>
300 <
typename boost::iterator_category<IC>::type>
::Category
303 typedef typename IC::value_type
Value;
338 #undef IteratorCirculatorTraits_RECURSES
DGtal is the top-level namespace which contains all DGtal functions and types.
Aim: Checks whether type IC is a circular or a classical iterator. Static value set to 'true' for a c...
BOOST_STATIC_CONSTANT(bool, value=IsCirculatorHelper::value)
detail::IsCirculator< IC, detail::HasNestedTypeType< IC >::value > IsCirculatorHelper
RandomAccessCategory Category
RandomAccessCategory Category
Aim: Provides nested types for both iterators and circulators: Type, Category, Value,...
IC::difference_type Difference
IteratorCirculatorType< IC >::Type Type
ToDGtalCategory< typename boost::iterator_category< IC >::type >::Category Category
Aim: Provides the type of IC as a nested type: either IteratorType or CirculatorType.
detail::IteratorCirculatorTypeImpl< IsCirculator< IC >::value >::Type Type
BidirectionalCategory Category
BidirectionalCategory Category
RandomAccessCategory Category
RandomAccessCategory Category
BidirectionalCategory Category
RandomAccessCategory Category
Aim: Provides the DGtal category matching C {ForwardCategory,BidirectionalCategory,...
Aim: Checks whether type IC has a nested type called 'Type' or not. NB: from en.wikipedia....
BOOST_STATIC_CONSTANT(bool, value=sizeof(test< IC >(0))==sizeof(yes))
static yes & test(typename C::Type *)
BOOST_STATIC_CONSTANT(bool, value=true)
Aim: In order to check whether type IC is a circular or a classical iterator, the nested type called ...
BOOST_STATIC_CONSTANT(bool, value=false)
BOOST_STATIC_CONSTANT(bool, value=IsCirculatorHelper::value)
IsCirculatorFromType< IC, typename IC::Type > IsCirculatorHelper
Aim: Checks whether type IC is a circular or a classical iterator. Static value set to 'true' for a c...
BOOST_STATIC_CONSTANT(bool, value=false)
Aim: Defines the Iterator or Circulator type as a nested type according to the value of b.