14 typedef typename std::map<double, T>::iterator
iterator;
15 const_iterator
begin()
const {
return val.begin();}
16 iterator
begin() {
return val.begin();}
17 const_iterator
end()
const {
return val.end();}
18 iterator
end() {
return val.end();}
26 template<
class It>
BinMap(It xstart, It xend,
const T& Initial_value)
33 val.insert(std::pair<double, T>(*xstart++, Initial_value));
40 template<
class It,
class C>
41 BinMap(It xstart, It xend,
const C& Initial_value_creator)
48 val.insert(std::pair<double, T>(*xstart++, Initial_value_creator()));
58 std::map<double, T>::const_iterator Itype;
59 Itype i = val.lower_bound(x);
61 return val.rbegin()->second;
68 std::map<double, T>::iterator Itype;
69 Itype i = val.lower_bound(x);
71 return val.rbegin()->second;
83 typedef typename std::map<double, T>::value_type vt;
84 for(
typename std::map<double, T>::const_iterator i = val.begin();
86 res.push_back(i->second);
90 std::map<double, T> val;
BinMap(It xstart, It xend, const C &Initial_value_creator)
Constructor.
std::vector< T > value() const
const_iterator end() const
BinMap(It xstart, It xend, const T &Initial_value)
Constructor.
This is a map that takes and index and returns a value.
std::map< double, T >::const_iterator const_iterator
Contains classes to abstract away details in various Spurr Radiative Transfer software.
const_iterator begin() const
std::map< double, T >::iterator iterator
const T & operator[](double x) const
Return bin that "x" falls into.