ATLAS Offline Software
Public Types | Public Member Functions | Public Attributes | List of all members
FSmap< _Key, _Tp > Class Template Reference

#include <FSmap.h>

Inheritance diagram for FSmap< _Key, _Tp >:
Collaboration diagram for FSmap< _Key, _Tp >:

Public Types

typedef _Key key_type
 
typedef std::map< _Key, _Tp >::iterator iterator
 
typedef std::map< _Key, _Tp >::const_iterator const_iterator
 

Public Member Functions

const_iterator find_closest (const key_type &k) const
 
iterator find_closest (const key_type &k)
 

Public Attributes

keys
 STL member. More...
 
elements
 STL member. More...
 

Detailed Description

template<class _Key, class _Tp>
class FSmap< _Key, _Tp >

Definition at line 11 of file FSmap.h.

Member Typedef Documentation

◆ const_iterator

template<class _Key , class _Tp >
typedef std::map< _Key , _Tp >::const_iterator FSmap< _Key, _Tp >::const_iterator

Definition at line 15 of file FSmap.h.

◆ iterator

template<class _Key , class _Tp >
typedef std::map< _Key , _Tp >::iterator FSmap< _Key, _Tp >::iterator

Definition at line 14 of file FSmap.h.

◆ key_type

template<class _Key , class _Tp >
typedef _Key FSmap< _Key, _Tp >::key_type

Definition at line 13 of file FSmap.h.

Member Function Documentation

◆ find_closest() [1/2]

template<class _Key , class _Tp >
iterator FSmap< _Key, _Tp >::find_closest ( const key_type k)
inline

Definition at line 32 of file FSmap.h.

32  {
34  iterator i=std::map< _Key , _Tp >::lower_bound(k);
36  --i;
37  return i;
38  }
39  if(i==std::map< _Key , _Tp >::begin()) return i;
40 
41  iterator il=i;
42  --il;
43 
44  if( fabs(il->first - k) > fabs(i->first - k) ) return i;
45  else return il;
46  };

◆ find_closest() [2/2]

template<class _Key , class _Tp >
const_iterator FSmap< _Key, _Tp >::find_closest ( const key_type k) const
inline

Definition at line 17 of file FSmap.h.

17  {
19  const_iterator i=std::map< _Key , _Tp >::lower_bound(k);
21  --i;
22  return i;
23  }
24  if(i==std::map< _Key , _Tp >::begin()) return i;
25 
27  --il;
28 
29  if( fabs(il->first - k) > fabs(i->first - k) ) return i;
30  else return il;
31  };

Member Data Documentation

◆ elements

T std::map< K, T >::elements
inherited

STL member.

◆ keys

K std::map< K, T >::keys
inherited

STL member.


The documentation for this class was generated from the following file:
PlotCalibFromCool.il
il
Definition: PlotCalibFromCool.py:381
PlotCalibFromCool.begin
begin
Definition: PlotCalibFromCool.py:94
mergePhysValFiles.end
end
Definition: DataQuality/DataQualityUtils/scripts/mergePhysValFiles.py:93
python.setupRTTAlg.size
int size
Definition: setupRTTAlg.py:39
lumiFormat.i
int i
Definition: lumiFormat.py:92
FSmap::iterator
std::map< _Key, _Tp >::iterator iterator
Definition: FSmap.h:14
fitman.k
k
Definition: fitman.py:528
FSmap::const_iterator
std::map< _Key, _Tp >::const_iterator const_iterator
Definition: FSmap.h:15