All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
Static Public Member Functions | List of all members
hit::details::CompiledGausFitCacheBaseStruct::InitializeFuncSumVector< NFunc, Func > Struct Template Reference

A helper class initializing the function vector. More...

#include <GausFitCache.h>

Static Public Member Functions

static void fill (CompiledGausFitCacheBaseStruct &cache)
 

Detailed Description

template<unsigned int NFunc, template< unsigned int > class Func>
struct hit::details::CompiledGausFitCacheBaseStruct::InitializeFuncSumVector< NFunc, Func >

A helper class initializing the function vector.

Template Parameters
NFuncthe maximum number of base functions in a function
Functhe function encapsulating object
Othersother template parameters of the function object

This helper class provides a static function fill() that fills the function vector of the specified CompiledGausFitCacheBaseStruct with a sequence on NFunc+1 functions, of types Func<0, Others...>, Func<1, Others...>, ... up to Func<NFunc, Others...> included. Each function is actually wrapped by a ROOT's TF1. Func type is a class, and the actual function must be found in the member Func::eval. Also the Func class is required to have a NParams static constexpr member whose value is the number of parameters that theeval()` function takes.

The template FuncSum is implementing all these requirements.

Definition at line 241 of file GausFitCache.h.

Member Function Documentation

template<unsigned int NFunc, template< unsigned int > class Func>
void hit::details::CompiledGausFitCacheBaseStruct::InitializeFuncSumVector< NFunc, Func >::fill ( CompiledGausFitCacheBaseStruct cache)
static

Definition at line 425 of file GausFitCache.h.

426  {
427  // first fill the lower functions
429  // then add one
430  cache.funcs.push_back(new TF1(
431  cache.FunctionName(NFunc).c_str(), Func<NFunc>::eval,
432  0., 1., Func<NFunc>::NParams
433  ));
434  } // InitializeFuncSumVector<NFunc, Func>::fill()
static void fill(CompiledGausFitCacheBaseStruct &cache)
Definition: GausFitCache.h:425

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