7 #ifndef SEQUENCE_INTERVAL_HPP_ 8 #define SEQUENCE_INTERVAL_HPP_ 11 #include "boost/functional/hash/hash_fwd.hpp" 12 #include "boost/numeric/interval.hpp" 13 #include "boost/numeric/interval/checking.hpp" 15 namespace vdj_pipe{
namespace detail{
23 static value_type
pos_inf() {
return std::numeric_limits<value_type>::max();}
25 static value_type
nan() {
return std::numeric_limits<value_type>::min();}
26 static bool is_nan(
const value_type v) {
return v == nan();}
29 static bool is_empty(
const value_type lo,
const value_type up) {
return lo == up;}
34 typedef boost::numeric::interval<
36 boost::numeric::interval_lib::policies<
37 boost::numeric::interval_lib::rounded_math<int>,
58 namespace boost{
namespace numeric {
63 return si.upper() >= 0;
70 boost::hash_combine(n, si.lower());
71 boost::hash_combine(n, si.upper());
77 template<
class ChT,
class Tr>
inline 79 std::basic_ostream<ChT,Tr>& os,
82 os <<
'[' << si.lower() <<
',' << si.upper() <<
']';
static value_type empty_upper()
Definition: sequence_interval.hpp:28
Definition: sanitize_string.cpp:15
static value_type nan()
Definition: sequence_interval.hpp:25
static bool is_empty(const value_type lo, const value_type up)
Definition: sequence_interval.hpp:29
int value_type
Definition: sequence_interval.hpp:22
Definition: sequence_interval.hpp:21
std::size_t hash_value(Base_id< S, V > const &id)
Definition: object_id_base.hpp:55
static bool is_nan(const value_type v)
Definition: sequence_interval.hpp:26
Main namespace of vdj_pipe library.
Definition: keywords_variable.hpp:11
sequence_interval sequence_interval_invalid()
Definition: sequence_interval.hpp:44
const std::size_t n
Definition: vector_set_test.cpp:26
Definition: sequence_interval.hpp:19
boost::numeric::interval< int, boost::numeric::interval_lib::policies< boost::numeric::interval_lib::rounded_math< int >, detail::Interval_checking_policy< int > > > sequence_interval
Definition: sequence_interval.hpp:40
bool is_valid(vdj_pipe::sequence_interval const &si)
Definition: sequence_interval.hpp:62
static value_type empty_lower()
Definition: sequence_interval.hpp:27
std::basic_ostream< ChT, Tr > & operator<<(std::basic_ostream< ChT, Tr > &os, Base_id< S, V > const &id)
Definition: object_id_base.hpp:46
static value_type neg_inf()
Definition: sequence_interval.hpp:24
static value_type pos_inf()
Definition: sequence_interval.hpp:23