Jpp  17.2.0
the software that should make you happy
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
Public Member Functions | Protected Attributes | List of all members
JSUPPORT::JTreeScannerInterface< T, JEvaluator_t > Struct Template Referenceabstract

Auxiliary interface for direct access of elements in ROOT TChain. More...

#include <JTreeScannerInterface.hh>

Public Member Functions

 JTreeScannerInterface (const JEvaluator_t &evaluator=JEvaluator_t())
 Constructor. More...
 
virtual Long64_t find (const double value) const =0
 Find index of element that is closest in value to given value. More...
 
template<class T >
Long64_t find (const T &object) const
 Find index of element that is closest in value to given object. More...
 
const JEvaluator_t & getEvaluator () const
 Get evaluator. More...
 

Protected Attributes

JEvaluator_t getValue
 

Detailed Description

template<class T, class JEvaluator_t = JNullType>
struct JSUPPORT::JTreeScannerInterface< T, JEvaluator_t >

Auxiliary interface for direct access of elements in ROOT TChain.

Specialiation of interface JTreeScannerInterface for ordered direct access of elements in ROOT TChain.

The optional second template argument is used to the determine the value of an element which defines the apparent order the elements in the TChain.

This interface extends the JTreeScannerInterface<JClass_t, JNullType> interface with the additional interface method to find a corresponding entry in the ROOT TChain.

Definition at line 34 of file JTreeScannerInterface.hh.

Constructor & Destructor Documentation

template<class T, class JEvaluator_t = JNullType>
JSUPPORT::JTreeScannerInterface< T, JEvaluator_t >::JTreeScannerInterface ( const JEvaluator_t &  evaluator = JEvaluator_t())
inline

Constructor.

Parameters
evaluatorevaluator

Definition at line 418 of file JTreeScannerInterface.hh.

418  :
419  getValue(evaluator)
420  {}

Member Function Documentation

template<class T, class JEvaluator_t = JNullType>
virtual Long64_t JSUPPORT::JTreeScannerInterface< T, JEvaluator_t >::find ( const double  value) const
pure virtual

Find index of element that is closest in value to given value.

Parameters
valuevalue
Returns
index (-1 in case of error)

Implemented in JSUPPORT::JTreeScanner< JAssertConversion< JDerived_t, JBase_t >, JEvaluator_t >.

template<class T, class JEvaluator_t = JNullType>
template<class T >
Long64_t JSUPPORT::JTreeScannerInterface< T, JEvaluator_t >::find ( const T object) const
inline

Find index of element that is closest in value to given object.

Parameters
objectobject
Returns
index (-1 in case of error)

Definition at line 439 of file JTreeScannerInterface.hh.

440  {
441  return this->find(getValue(object));
442  }
virtual Long64_t find(const double value) const =0
Find index of element that is closest in value to given value.
template<class T, class JEvaluator_t = JNullType>
const JEvaluator_t& JSUPPORT::JTreeScannerInterface< T, JEvaluator_t >::getEvaluator ( ) const
inline

Get evaluator.

Returns
evaluator

Definition at line 450 of file JTreeScannerInterface.hh.

451  {
452  return getValue;
453  }

Member Data Documentation

template<class T, class JEvaluator_t = JNullType>
JEvaluator_t JSUPPORT::JTreeScannerInterface< T, JEvaluator_t >::getValue
protected

Definition at line 457 of file JTreeScannerInterface.hh.


The documentation for this struct was generated from the following file: