Ignore:
Timestamp:
Sep 29, 2007, 4:18:52 AM (14 years ago)
Author:
Peter
Message:

refactoring add function in Averagers, refs #246

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/yat/statistics/AveragerPairWeighted.h

    r899 r914  
    2828
    2929#include "AveragerWeighted.h"
     30
     31#include "yat/utility/IteratorTraits.h"
    3032
    3133#include <cmath>
     
    176178
    177179  /**
    178      \brief adding a ranges of values to AveragerPairWeighted \a ap
    179   */
     180     \brief adding a ranges of values to AveragerPair \a ap
     181   */
    180182  template <class Iter1, class Iter2>
    181183  void add(AveragerPairWeighted& ap, Iter1 first1, Iter1 last1, Iter2 first2)
    182184  {
    183185    for ( ; first1 != last1; ++first1, ++first2)
    184       ap.add(first1.data(), first2.data(),first1.weight(),first2.weight());
     186      ap.add(utility::iterator_traits_data(first1),
     187             utility::iterator_traits_data(first2),
     188             utility::iterator_traits_weight(first1),
     189             utility::iterator_traits_weight(first2));
    185190  }
    186 
    187 
    188191
    189192
Note: See TracChangeset for help on using the changeset viewer.