src/simpleNbox.cpp
//------------------------------------------------------------------------------
/*! \brief      Sum a string->double map
 *  \param      pool to sum over
 *  \returns    Sum of the unitvals in the map
 *  \exception  If the map is empty
 */
\brief      Sum a string->double map
\param      pool to sum over
\returns    Sum of the unitvals in the map
\exception  If the map is empty
\ brief Sum a string - > double map \ param pool to sum over \ returns Sum of the unitvals in the map \ exception If the map is empty
double SimpleNbox::sum_map( double_stringmap pool ) const
{
    H_ASSERT( pool.size(), "can't sum an empty map" );
    double sum = 0.0;
    for( double_stringmap::const_iterator it = pool.begin(); it != pool.end(); it++ )
        sum = sum + it->second;
    return sum;
}
double SimpleNbox :: sum_map ( double_stringmap pool ) const { H_ASSERT ( pool . size ( ) , " " ) ; double sum = 0.0 ; for ( double_stringmap :: const_iterator it = pool . begin ( ) ; it != pool . end ( ) ; it ++ ) sum = sum + it -> second ; return sum ; }
\brief      Sum a string->double map
  \param      pool to sum over
  \returns    Sum of the unitvals in the map
  \exception  If the map is empty
\ brief Sum a string - > double map \ param pool to sum over \ returns Sum of the unitvals in the map \ exception If the map is empty