1 #ifndef _theplu_yat_utility_concept_check_
2 #define _theplu_yat_utility_concept_check_
28 #include "iterator_traits.h"
30 #include <boost/concept_archetype.hpp>
31 #include <boost/concept_check.hpp>
59 #ifdef YAT_HAVE_BOOST_CONCEPT_WITH_CONSTRUCTOR
83 row_iter_ = t_.end_row(0);
85 col_iter_ = t_.end_column(0);
91 BOOST_CONCEPT_ASSERT((boost::RandomAccessIterator<const_iterator>));
92 BOOST_CONCEPT_ASSERT((boost::RandomAccessIterator<const_row_iterator>));
93 BOOST_CONCEPT_ASSERT((boost::RandomAccessIterator<const_column_iterator>));
97 void some_func(
size_t x)
const {}
141 row_iter_ = t_.end_row(0);
143 col_iter_ = t_.end_column(0);
146 using boost::Mutable_RandomAccessIterator;
147 BOOST_CONCEPT_ASSERT((Mutable_RandomAccessIterator<iterator>));
148 BOOST_CONCEPT_ASSERT((Mutable_RandomAccessIterator<row_iterator>));
149 BOOST_CONCEPT_ASSERT((Mutable_RandomAccessIterator<column_iterator>));
176 :
public boost::Assignable<T>
177 ,
public boost::EqualityComparable<T>
178 ,
public boost::DefaultConstructible<T>
185 typedef typename std::iterator_traits<T>::value_type
value_type;
189 typedef typename std::iterator_traits<T>::pointer
pointer;
191 typedef typename std::iterator_traits<T>::reference
reference;
230 typedef typename std::iterator_traits<T>::value_type
value_type;
244 BOOST_CONCEPT_ASSERT((boost::Convertible<value_type, double>));
249 BOOST_CONCEPT_ASSERT((boost::Convertible<value_type, DataWeight>));
281 boost::random_access_iterator_archetype<double> unweighted;
282 boost::random_access_iterator_archetype<DataWeight> weighted;
284 d += distance_(unweighted, unweighted, unweighted);
285 d += distance_(unweighted, unweighted, weighted);
286 d += distance_(weighted, weighted, unweighted);
287 d += distance_(weighted, weighted, weighted);
292 void func(
double x) {}