![]() System : Linux absol.cf 5.4.0-198-generic #218-Ubuntu SMP Fri Sep 27 20:18:53 UTC 2024 x86_64 User : www-data ( 33) PHP Version : 7.4.33 Disable Function : pcntl_alarm,pcntl_fork,pcntl_waitpid,pcntl_wait,pcntl_wifexited,pcntl_wifstopped,pcntl_wifsignaled,pcntl_wifcontinued,pcntl_wexitstatus,pcntl_wtermsig,pcntl_wstopsig,pcntl_signal,pcntl_signal_get_handler,pcntl_signal_dispatch,pcntl_get_last_error,pcntl_strerror,pcntl_sigprocmask,pcntl_sigwaitinfo,pcntl_sigtimedwait,pcntl_exec,pcntl_getpriority,pcntl_setpriority,pcntl_async_signals,pcntl_unshare, Directory : /usr/include/boost/icl/ |
Upload File : |
/*-----------------------------------------------------------------------------+ Copyright (c) 2010-2010: Joachim Faulhaber +------------------------------------------------------------------------------+ Distributed under the Boost Software License, Version 1.0. (See accompanying file LICENCE.txt or copy at http://www.boost.org/LICENSE_1_0.txt) +-----------------------------------------------------------------------------*/ #ifndef BOOST_ICL_INTERVAL_TRAITS_HPP_JOFA_100926 #define BOOST_ICL_INTERVAL_TRAITS_HPP_JOFA_100926 #include <boost/icl/type_traits/domain_type_of.hpp> #include <boost/icl/type_traits/difference_type_of.hpp> #include <boost/icl/type_traits/size_type_of.hpp> namespace boost{ namespace icl { template<class Type> struct interval_traits; template<class Type> struct domain_type_of<interval_traits<Type> > { typedef typename interval_traits<Type>::domain_type type; }; //------------------------------------------------------------------------------ //- Adapter class //------------------------------------------------------------------------------ template<class Type> struct interval_traits { typedef interval_traits type; typedef typename domain_type_of<Type>::type domain_type; static Type construct(const domain_type& lo, const domain_type& up); static domain_type upper(const Type& inter_val); static domain_type lower(const Type& inter_val); }; template<class Type> struct difference_type_of<interval_traits<Type> > { typedef typename interval_traits<Type>::domain_type domain_type; typedef typename difference_type_of<domain_type>::type type; }; template<class Type> struct size_type_of<interval_traits<Type> > { typedef typename interval_traits<Type>::domain_type domain_type; typedef typename size_type_of<domain_type>::type type; }; }} // namespace boost icl #endif