21 #ifndef BOLT_FACADE_ITERATOR_CATEGORY_H
22 # define BOLT_FACADE_ITERATOR_CATEGORY_H
26 #include <bolt/cl/iterator/iterator_categories.h>
39 : std::input_iterator_tag
47 operator std::output_iterator_tag()
const
49 return std::output_iterator_tag();
67 template <
typename Traversal,
typename ValueParam,
typename Reference>
69 : bolt::cl::detail::eval_if<
70 bolt::cl::detail::and_<
71 std::is_reference<Reference>
72 , std::is_convertible<Traversal,forward_traversal_tag>
74 , bolt::cl::detail::eval_if<
75 std::is_convertible<Traversal,random_access_traversal_tag>
76 , bolt::cl::detail::identity_<std::random_access_iterator_tag>
77 , bolt::cl::detail::if_<
78 std::is_convertible<Traversal,bidirectional_traversal_tag>
79 , std::bidirectional_iterator_tag
80 , std::forward_iterator_tag
83 , bolt::cl::detail::eval_if<
84 bolt::cl::detail::and_<
85 std::is_convertible<Traversal, single_pass_traversal_tag>
87 , std::is_convertible<Reference, ValueParam>
89 , bolt::cl::detail::identity_<std::input_iterator_tag>
90 , bolt::cl::detail::identity_<Traversal>
99 : bolt::cl::detail::or_<
100 std::is_convertible<T,std::input_iterator_tag>
101 , std::is_convertible<T,std::output_iterator_tag>
108 : std::is_convertible<T,incrementable_traversal_tag>
117 template <
class Category,
class Traversal>
119 : Category, Traversal
124 template <
class Traversal,
class ValueParam,
class Reference>
128 Traversal,ValueParam,Reference
131 typedef typename bolt::cl::detail::if_<
144 template <
class CategoryOrTraversal,
class ValueParam,
class Reference>
146 : bolt::cl::detail::eval_if<
147 is_iterator_category<CategoryOrTraversal>
148 , bolt::cl::detail::identity_<CategoryOrTraversal>
149 , facade_iterator_category_impl<CategoryOrTraversal,ValueParam,Reference>
157 #endif // BOLT_FACADE_ITERATOR_CATEGORY_H