#ifdef __cplusplus extern "C" { #endif #include "HROOTType.h" #include "HROOTTNamed.h" #include "HROOTTObject.h" #include "HROOTDeletable.h" #undef ROOT_TFORMULA_DECLARATIONVIRT #define ROOT_TFORMULA_DECLARATIONVIRT(Type) \ int Type ## _Compile ( Type ## _p p, const char * expression ); \ void Type ## _Clear ( Type ## _p p, const char * option ); \ double Type ## _DefinedValue ( Type ## _p p, int code ); \ double Type ## _Eval ( Type ## _p p, double x, double y, double z, double t ); \ double Type ## _EvalParOld ( Type ## _p p, double * x, double * params ); \ double Type ## _EvalPar ( Type ## _p p, double * x, double * params ); \ int Type ## _GetNdim ( Type ## _p p ); \ int Type ## _GetNpar ( Type ## _p p ); \ int Type ## _GetNumber ( Type ## _p p ); \ int Type ## _GetParNumber ( Type ## _p p, const char * name ); \ int Type ## _IsLinear ( Type ## _p p ); \ int Type ## _IsNormalized ( Type ## _p p ); \ void Type ## _SetNumber ( Type ## _p p, int number ); \ void Type ## _SetParameter ( Type ## _p p, const char * name, double parvalue ); \ void Type ## _SetParameters ( Type ## _p p, double * params ); \ void Type ## _SetParName ( Type ## _p p, int ipar, const char * name ); \ void Type ## _SetParNames ( Type ## _p p, const char * name0, const char * name1, const char * name2, const char * name3, const char * name4, const char * name5, const char * name6, const char * name7, const char * name8, const char * name9, const char * name10 ); \ void Type ## _Update ( Type ## _p p ) #undef ROOT_TFORMULA_DECLARATIONNONVIRT #define ROOT_TFORMULA_DECLARATIONNONVIRT(Type) \ Type ## _p Type ## _newTFormula ( const char * name, const char * formula ); \ void Type ## _tFormulaOptimize ( Type ## _p p ); \ double Type ## _tFormulaGetParameter ( Type ## _p p, const char * name ) #undef ROOT_TFORMULA_DEFINITIONVIRT #define ROOT_TFORMULA_DEFINITIONVIRT(Type)\ int Type ## _Compile ( Type ## _p p, const char * expression )\ {\ return to_nonconst(p)->Compile(expression);\ }\ void Type ## _Clear ( Type ## _p p, const char * option )\ {\ to_nonconst(p)->Clear(option);\ }\ double Type ## _DefinedValue ( Type ## _p p, int code )\ {\ return to_nonconst(p)->DefinedValue(code);\ }\ double Type ## _Eval ( Type ## _p p, double x, double y, double z, double t )\ {\ return to_nonconst(p)->Eval(x, y, z, t);\ }\ double Type ## _EvalParOld ( Type ## _p p, double * x, double * params )\ {\ return to_nonconst(p)->EvalParOld(x, params);\ }\ double Type ## _EvalPar ( Type ## _p p, double * x, double * params )\ {\ return to_nonconst(p)->EvalPar(x, params);\ }\ int Type ## _GetNdim ( Type ## _p p )\ {\ return to_nonconst(p)->GetNdim();\ }\ int Type ## _GetNpar ( Type ## _p p )\ {\ return to_nonconst(p)->GetNpar();\ }\ int Type ## _GetNumber ( Type ## _p p )\ {\ return to_nonconst(p)->GetNumber();\ }\ int Type ## _GetParNumber ( Type ## _p p, const char * name )\ {\ return to_nonconst(p)->GetParNumber(name);\ }\ int Type ## _IsLinear ( Type ## _p p )\ {\ return to_nonconst(p)->IsLinear();\ }\ int Type ## _IsNormalized ( Type ## _p p )\ {\ return to_nonconst(p)->IsNormalized();\ }\ void Type ## _SetNumber ( Type ## _p p, int number )\ {\ to_nonconst(p)->SetNumber(number);\ }\ void Type ## _SetParameter ( Type ## _p p, const char * name, double parvalue )\ {\ to_nonconst(p)->SetParameter(name, parvalue);\ }\ void Type ## _SetParameters ( Type ## _p p, double * params )\ {\ to_nonconst(p)->SetParameters(params);\ }\ void Type ## _SetParName ( Type ## _p p, int ipar, const char * name )\ {\ to_nonconst(p)->SetParName(ipar, name);\ }\ void Type ## _SetParNames ( Type ## _p p, const char * name0, const char * name1, const char * name2, const char * name3, const char * name4, const char * name5, const char * name6, const char * name7, const char * name8, const char * name9, const char * name10 )\ {\ to_nonconst(p)->SetParNames(name0, name1, name2, name3, name4, name5, name6, name7, name8, name9, name10);\ }\ void Type ## _Update ( Type ## _p p )\ {\ to_nonconst(p)->Update();\ } #undef ROOT_TFORMULA_DEFINITIONNONVIRT #define ROOT_TFORMULA_DEFINITIONNONVIRT(Type)\ Type ## _p Type ## _newTFormula ( const char * name, const char * formula )\ {\ Type * newp = new Type (name, formula); \ return to_nonconst(newp);\ }\ void Type ## _tFormulaOptimize ( Type ## _p p )\ {\ to_nonconst(p)->Optimize();\ }\ double Type ## _tFormulaGetParameter ( Type ## _p p, const char * name )\ {\ return to_nonconst(p)->GetParameter(name);\ } ROOT_TNAMED_DECLARATIONVIRT(TFormula); ROOT_TOBJECT_DECLARATIONVIRT(TFormula); ROOT_DELETABLE_DECLARATIONVIRT(TFormula); ROOT_TFORMULA_DECLARATIONVIRT(TFormula); ROOT_TFORMULA_DECLARATIONNONVIRT(TFormula); #ifdef __cplusplus } #endif