Boost  v1.57.0
doxygen for www.boost.org
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Modules Pages
boost::units::detail Namespace Reference

Classes

struct  check_system
 
struct  check_system< heterogeneous_system< heterogeneous_system_impl< System, Dimension, Scale > >, Dimension >
 
struct  check_system< homogeneous_system< L >, Dimensions >
 
struct  dim_tag
 
struct  disable_if_is_same
 
struct  disable_if_is_same< T, T >
 
struct  divide_systems
 
struct  format_name_impl
 
struct  format_raw_name_impl
 
struct  format_raw_symbol_impl
 
struct  format_symbol_impl
 
struct  get_scale_list_of_heterogeneous_system_impl
 
struct  get_scale_list_of_heterogeneous_system_impl< 0 >
 
struct  is_base_unit
 
struct  is_base_unit< T, typename T::boost_units_is_base_unit_type >
 
struct  is_empty_dim< heterogeneous_system_dim< Unit1, Exponent1 > >
 
struct  is_narrowing_conversion_impl
 
struct  is_non_narrowing_conversion
 
struct  is_non_narrowing_conversion< long double, double >
 
struct  is_zero
 
struct  is_zero< static_rational< 0 > >
 
struct  make_heterogeneous_system
 
struct  make_heterogeneous_system< Dimensions, heterogeneous_system< T > >
 
struct  make_heterogeneous_system_impl
 
struct  make_heterogeneous_system_impl< 0 >
 
struct  multiply_systems
 
struct  name_string_impl
 
struct  name_string_impl< 0 >
 
struct  name_string_impl< 1 >
 
struct  print_default_t
 
struct  print_scale_t
 
struct  quantity_cast_helper
 helper class for quantity_cast More...
 
struct  quantity_cast_helper< Y, const quantity< Unit, X > >
 specialization for casting to the value type More...
 
struct  quantity_cast_helper< Y, quantity< Unit, X > >
 specialization for casting to the value type More...
 
struct  scale_name_string_impl
 
struct  scale_name_string_impl< 0 >
 
struct  scale_symbol_string_impl
 
struct  scale_symbol_string_impl< 0 >
 
struct  static_rational_tag
 
struct  symbol_string_impl
 
struct  symbol_string_impl< 0 >
 
struct  symbol_string_impl< 1 >
 
struct  unscale_heterogeneous_system_impl
 
struct  unscale_heterogeneous_system_impl< 0 >
 
struct  xalloc_key_holder
 
struct  xalloc_key_initializer_t
 

Typedefs

typedef list< scale
< 10, static_rational
<-24 > >, list< scale
< 10, static_rational
<-21 > >, list< scale
< 10, static_rational
<-18 > >, list< scale
< 10, static_rational
<-15 > >, list< scale
< 10, static_rational
<-12 > >, list< scale
< 10, static_rational
<-9 > >, list< scale
< 10, static_rational
<-6 > >, list< scale
< 10, static_rational
<-3 > >, list< scale
< 10, static_rational
< 0 > >, list< scale
< 10, static_rational
< 3 > >, list< scale
< 10, static_rational
< 6 > >, list< scale
< 10, static_rational
< 9 > >, list< scale
< 10, static_rational
< 12 > >, list< scale
< 10, static_rational
< 15 > >, list< scale
< 10, static_rational
< 18 > >, list< scale
< 10, static_rational
< 21 > >, list< scale
< 10, static_rational
< 24 > >, list< scale
< 10, static_rational
< 27 > >, dimensionless_type > > > > > > > > > > > > > > > > > > 
engineering_prefixes
 
typedef list< scale
< 2, static_rational
< 10 > >, list< scale
< 2, static_rational
< 20 > >, list< scale
< 2, static_rational
< 30 > >, list< scale
< 2, static_rational
< 40 > >, list< scale
< 2, static_rational
< 50 > >, list< scale
< 2, static_rational
< 60 > >, list< scale
< 2, static_rational
< 70 > >, list< scale
< 2, static_rational
< 80 > >, list< scale
< 2, static_rational
< 90 > >, dimensionless_type > > > > > > > > > 
binary_prefixes
 

Functions

template<integer_type N, integer_type D>
std::string exponent_string (const static_rational< N, D > &r)
 
template<>
std::string exponent_string (const static_rational< 1 > &)
 
template<class T >
std::string base_unit_symbol_string (const T &)
 
template<class T >
std::string base_unit_name_string (const T &)
 
template<class Dimension , class System , class SubFormatter >
std::string to_string_impl (const unit< Dimension, System > &, SubFormatter f)
 
template<class Dimension , class Units , class Subformatter >
std::string to_string_impl (const unit< Dimension, heterogeneous_system< heterogeneous_system_impl< Units, Dimension, dimensionless_type > > > &, Subformatter f)
 INTERNAL ONLY. More...
 
template<class Subformatter >
std::string to_string_impl (const unit< dimensionless_type, heterogeneous_system< heterogeneous_system_impl< dimensionless_type, dimensionless_type, dimensionless_type > > > &, Subformatter)
 INTERNAL ONLY. More...
 
template<class Scale , class Subformatter >
std::string to_string_impl (const unit< dimensionless_type, heterogeneous_system< heterogeneous_system_impl< dimensionless_type, dimensionless_type, Scale > > > &, Subformatter f)
 INTERNAL ONLY. More...
 
template<class Dimension , class Units , class Scale , class Subformatter >
std::string to_string_impl (const unit< Dimension, heterogeneous_system< heterogeneous_system_impl< Units, Dimension, Scale > > > &, Subformatter f)
 INTERNAL ONLY. More...
 
template<class Dimension , class Unit , class Scale , class Subformatter >
std::string to_string_impl (const unit< Dimension, heterogeneous_system< heterogeneous_system_impl< list< heterogeneous_system_dim< Unit, static_rational< 1 > >, dimensionless_type >, Dimension, Scale > > > &, Subformatter f)
 INTERNAL ONLY. More...
 
template<class Dimension , class Unit , class Subformatter >
std::string to_string_impl (const unit< Dimension, heterogeneous_system< heterogeneous_system_impl< list< heterogeneous_system_dim< Unit, static_rational< 1 > >, dimensionless_type >, Dimension, dimensionless_type > > > &, Subformatter f)
 INTERNAL ONLY. More...
 
template<class Dimension , class Unit , class UnitScale , class Scale , class Subformatter >
std::string to_string_impl (const unit< Dimension, heterogeneous_system< heterogeneous_system_impl< list< heterogeneous_system_dim< scaled_base_unit< Unit, UnitScale >, static_rational< 1 > >, dimensionless_type >, Dimension, Scale > > > &, Subformatter f, typename base_unit_info< scaled_base_unit< Unit, UnitScale > >::base_unit_info_primary_template *=0)
 INTERNAL ONLY. More...
 
template<class Dimension , class Unit , class UnitScale , class Subformatter >
std::string to_string_impl (const unit< Dimension, heterogeneous_system< heterogeneous_system_impl< list< heterogeneous_system_dim< scaled_base_unit< Unit, UnitScale >, static_rational< 1 > >, dimensionless_type >, Dimension, dimensionless_type > > > &, Subformatter f, typename base_unit_info< scaled_base_unit< Unit, UnitScale > >::base_unit_info_primary_template *=0)
 INTERNAL ONLY. More...
 
template<class Char , class Traits >
void do_print (std::basic_ostream< Char, Traits > &os, const std::string &s)
 
void do_print (std::ostream &os, const std::string &s)
 
template<class Char , class Traits >
void do_print (std::basic_ostream< Char, Traits > &os, const char *s)
 
template<class End , class Prev , class T , class F >
bool find_matching_scale_impl (End, End, Prev, T, double, F)
 
template<class Begin , class End , class Prev , class T , class F >
bool find_matching_scale_impl (Begin, End end, Prev prev, T t, double x, F f)
 
template<class End , class T , class F >
bool find_matching_scale_i (End, End, T, double, F)
 
template<class Begin , class End , class T , class F >
bool find_matching_scale_i (Begin, End end, T t, double x, F f)
 
template<class Scales , class T , class F >
bool find_matching_scale (T t, double x, F f)
 
template<class Os , class Quantity >
print_default_t< Os, Quantity > print_default (Os &os, const Quantity &q)
 
template<class Os >
print_scale_t< Os > print_scale (Os &os, bool &prefixed)
 
template<class Dimension , class Units , class Scale , class Subformatter >
std::string maybe_parenthesize (const unit< Dimension, heterogeneous_system< heterogeneous_system_impl< Units, Dimension, Scale > > > &, Subformatter f)
 INTERNAL ONLY. More...
 
template<class Dimension , class Unit , class Scale , class Subformatter >
std::string maybe_parenthesize (const unit< Dimension, heterogeneous_system< heterogeneous_system_impl< list< heterogeneous_system_dim< Unit, static_rational< 1 > >, dimensionless_type >, Dimension, Scale > > > &, Subformatter f)
 INTERNAL ONLY. More...
 
template<class Prefixes , class CharT , class Traits , class Unit , class T , class F >
void do_print_prefixed_impl (std::basic_ostream< CharT, Traits > &os, const quantity< Unit, T > &q, F default_)
 
template<class Prefixes , class CharT , class Traits , class Dimension , class BaseUnit , class BaseScale , class Scale , class T >
base_unit_info
< scaled_base_unit< BaseUnit,
Scale >
>::base_unit_info_primary_template 
do_print_prefixed (std::basic_ostream< CharT, Traits > &os, const quantity< unit< Dimension, heterogeneous_system< heterogeneous_system_impl< list< heterogeneous_system_dim< scaled_base_unit< BaseUnit, BaseScale >, static_rational< 1 > >, dimensionless_type >, Dimension, Scale > > >, T > &q)
 
template<class Prefixes , class CharT , class Traits , class Dimension , class L , class Scale , class T >
void do_print_prefixed (std::basic_ostream< CharT, Traits > &os, const quantity< unit< Dimension, heterogeneous_system< heterogeneous_system_impl< L, Dimension, Scale > > >, T > &q)
 
template<class Prefixes , class CharT , class Traits , class Dimension , class System , class T >
void do_print_prefixed (std::basic_ostream< CharT, Traits > &os, const quantity< unit< Dimension, System >, T > &q)
 
template<class Prefixes , class CharT , class Traits , class Unit , class T >
void do_print_prefixed (std::basic_ostream< CharT, Traits > &os, const quantity< Unit, T > &q)
 
template<class Prefixes , class CharT , class Traits , class Unit , class T >
void maybe_print_prefixed (std::basic_ostream< CharT, Traits > &os, const quantity< Unit, T > &q, mpl::true_)
 
template<class Prefixes , class CharT , class Traits , class Unit , class T >
void maybe_print_prefixed (std::basic_ostream< CharT, Traits > &os, const quantity< Unit, T > &q, mpl::false_)
 
mpl::true_ test_norm (double)
 
mpl::false_ test_norm (one)
 

Typedef Documentation

Function Documentation

template<class T >
std::string boost::units::detail::base_unit_name_string ( const T )
inline
template<class T >
std::string boost::units::detail::base_unit_symbol_string ( const T )
inline
template<class Char , class Traits >
void boost::units::detail::do_print ( std::basic_ostream< Char, Traits > &  os,
const std::string &  s 
)
inline
void boost::units::detail::do_print ( std::ostream &  os,
const std::string &  s 
)
inline

References boost::asio::s.

template<class Char , class Traits >
void boost::units::detail::do_print ( std::basic_ostream< Char, Traits > &  os,
const char *  s 
)
inline

References boost::asio::s.

template<class Prefixes , class CharT , class Traits , class Dimension , class BaseUnit , class BaseScale , class Scale , class T >
base_unit_info< scaled_base_unit<BaseUnit, Scale>>::base_unit_info_primary_template boost::units::detail::do_print_prefixed ( std::basic_ostream< CharT, Traits > &  os,
const quantity< unit< Dimension, heterogeneous_system< heterogeneous_system_impl< list< heterogeneous_system_dim< scaled_base_unit< BaseUnit, BaseScale >, static_rational< 1 > >, dimensionless_type >, Dimension, Scale > > >, T > &  q 
)

References print_default(), and T.

template<class Prefixes , class CharT , class Traits , class Dimension , class L , class Scale , class T >
void boost::units::detail::do_print_prefixed ( std::basic_ostream< CharT, Traits > &  os,
const quantity< unit< Dimension, heterogeneous_system< heterogeneous_system_impl< L, Dimension, Scale > > >, T > &  q 
)
template<class Prefixes , class CharT , class Traits , class Dimension , class System , class T >
void boost::units::detail::do_print_prefixed ( std::basic_ostream< CharT, Traits > &  os,
const quantity< unit< Dimension, System >, T > &  q 
)

References T.

template<class Prefixes , class CharT , class Traits , class Unit , class T >
void boost::units::detail::do_print_prefixed ( std::basic_ostream< CharT, Traits > &  os,
const quantity< Unit, T > &  q 
)

References print_default().

template<class Prefixes , class CharT , class Traits , class Unit , class T , class F >
void boost::units::detail::do_print_prefixed_impl ( std::basic_ostream< CharT, Traits > &  os,
const quantity< Unit, T > &  q,
default_ 
)
template<integer_type N, integer_type D>
std::string boost::units::detail::exponent_string ( const static_rational< N, D > &  r)
inline
Returns
exponent string like "^1/2".

References boost::units::to_string().

Referenced by base_unit_name_string(), and base_unit_symbol_string().

template<>
std::string boost::units::detail::exponent_string ( const static_rational< 1 > &  )
inline
Returns
empty exponent string for integer rational like 2.
template<class Scales , class T , class F >
bool boost::units::detail::find_matching_scale ( T  t,
double  x,
f 
)
template<class End , class T , class F >
bool boost::units::detail::find_matching_scale_i ( End  ,
End  ,
T  ,
double  ,
 
)

Referenced by find_matching_scale().

template<class Begin , class End , class T , class F >
bool boost::units::detail::find_matching_scale_i ( Begin  ,
End  end,
T  t,
double  x,
f 
)
template<class End , class Prev , class T , class F >
bool boost::units::detail::find_matching_scale_impl ( End  ,
End  ,
Prev  ,
T  ,
double  ,
 
)
template<class Begin , class End , class Prev , class T , class F >
bool boost::units::detail::find_matching_scale_impl ( Begin  ,
End  end,
Prev  prev,
T  t,
double  x,
f 
)
template<class Dimension , class Units , class Scale , class Subformatter >
std::string boost::units::detail::maybe_parenthesize ( const unit< Dimension, heterogeneous_system< heterogeneous_system_impl< Units, Dimension, Scale > > > &  ,
Subformatter  f 
)
inline

INTERNAL ONLY.

References boost::str().

Referenced by do_print_prefixed_impl().

template<class Dimension , class Unit , class Scale , class Subformatter >
std::string boost::units::detail::maybe_parenthesize ( const unit< Dimension, heterogeneous_system< heterogeneous_system_impl< list< heterogeneous_system_dim< Unit, static_rational< 1 > >, dimensionless_type >, Dimension, Scale > > > &  ,
Subformatter  f 
)
inline

INTERNAL ONLY.

template<class Prefixes , class CharT , class Traits , class Unit , class T >
void boost::units::detail::maybe_print_prefixed ( std::basic_ostream< CharT, Traits > &  os,
const quantity< Unit, T > &  q,
mpl::true_   
)
template<class Prefixes , class CharT , class Traits , class Unit , class T >
void boost::units::detail::maybe_print_prefixed ( std::basic_ostream< CharT, Traits > &  os,
const quantity< Unit, T > &  q,
mpl::false_   
)

References print_default().

template<class Os , class Quantity >
print_default_t<Os, Quantity> boost::units::detail::print_default ( Os &  os,
const Quantity &  q 
)
template<class Os >
print_scale_t<Os> boost::units::detail::print_scale ( Os &  os,
bool &  prefixed 
)

Referenced by do_print_prefixed_impl().

mpl::true_ boost::units::detail::test_norm ( double  )
inline
mpl::false_ boost::units::detail::test_norm ( one  )
inline
template<class Dimension , class System , class SubFormatter >
std::string boost::units::detail::to_string_impl ( const unit< Dimension, System > &  ,
SubFormatter  f 
)
inline
template<class Dimension , class Units , class Subformatter >
std::string boost::units::detail::to_string_impl ( const unit< Dimension, heterogeneous_system< heterogeneous_system_impl< Units, Dimension, dimensionless_type > > > &  ,
Subformatter  f 
)
inline

INTERNAL ONLY.

References boost::str().

template<class Subformatter >
std::string boost::units::detail::to_string_impl ( const unit< dimensionless_type, heterogeneous_system< heterogeneous_system_impl< dimensionless_type, dimensionless_type, dimensionless_type > > > &  ,
Subformatter   
)
inline

INTERNAL ONLY.

template<class Scale , class Subformatter >
std::string boost::units::detail::to_string_impl ( const unit< dimensionless_type, heterogeneous_system< heterogeneous_system_impl< dimensionless_type, dimensionless_type, Scale > > > &  ,
Subformatter  f 
)
inline

INTERNAL ONLY.

References boost::str().

template<class Dimension , class Units , class Scale , class Subformatter >
std::string boost::units::detail::to_string_impl ( const unit< Dimension, heterogeneous_system< heterogeneous_system_impl< Units, Dimension, Scale > > > &  ,
Subformatter  f 
)
inline

INTERNAL ONLY.

References boost::str().

template<class Dimension , class Unit , class Scale , class Subformatter >
std::string boost::units::detail::to_string_impl ( const unit< Dimension, heterogeneous_system< heterogeneous_system_impl< list< heterogeneous_system_dim< Unit, static_rational< 1 > >, dimensionless_type >, Dimension, Scale > > > &  ,
Subformatter  f 
)
inline

INTERNAL ONLY.

References boost::str().

template<class Dimension , class Unit , class Subformatter >
std::string boost::units::detail::to_string_impl ( const unit< Dimension, heterogeneous_system< heterogeneous_system_impl< list< heterogeneous_system_dim< Unit, static_rational< 1 > >, dimensionless_type >, Dimension, dimensionless_type > > > &  ,
Subformatter  f 
)
inline

INTERNAL ONLY.

References boost::str().

template<class Dimension , class Unit , class UnitScale , class Scale , class Subformatter >
std::string boost::units::detail::to_string_impl ( const unit< Dimension, heterogeneous_system< heterogeneous_system_impl< list< heterogeneous_system_dim< scaled_base_unit< Unit, UnitScale >, static_rational< 1 > >, dimensionless_type >, Dimension, Scale > > > &  ,
Subformatter  f,
typename base_unit_info< scaled_base_unit< Unit, UnitScale > >::base_unit_info_primary_template *  = 0 
)
inline

INTERNAL ONLY.

References times().

template<class Dimension , class Unit , class UnitScale , class Subformatter >
std::string boost::units::detail::to_string_impl ( const unit< Dimension, heterogeneous_system< heterogeneous_system_impl< list< heterogeneous_system_dim< scaled_base_unit< Unit, UnitScale >, static_rational< 1 > >, dimensionless_type >, Dimension, dimensionless_type > > > &  ,
Subformatter  f,
typename base_unit_info< scaled_base_unit< Unit, UnitScale > >::base_unit_info_primary_template *  = 0 
)
inline

INTERNAL ONLY.

References boost::str().