Boost C++ Libraries Home Libraries People FAQ More

PrevUpHomeNext

Function template operator<<

boost::units::operator<< — Print a unit as a list of base units and their exponents.

Synopsis

// In header: <boost/units/io.hpp>


template<typename Char, typename Traits, typename Dimension, typename System> 
  std::basic_ostream< Char, Traits > & 
  operator<<(std::basic_ostream< Char, Traits > & os, 
             const unit< Dimension, System > & u);

Description

for symbol_format outputs e.g. "m s^-1" or "J". for name_format outputs e.g. "meter second^-1" or "joule". for raw_format outputs e.g. "m s^-1" or "meter kilogram^2 second^-2". for typename_format outputs the typename itself (currently demangled only on GCC).


PrevUpHomeNext