Logo ROOT  
Reference Guide
TRInternalFunction.h
Go to the documentation of this file.
1// @(#)root/r:$Id$
2// Author: Omar Zapata Omar.Zapata@cern.ch 07/06/2014
3
4
5/*************************************************************************
6 * Copyright (C) 1995-2021, Rene Brun and Fons Rademakers. *
7 * All rights reserved. *
8 * *
9 * For the licensing terms see $ROOTSYS/LICENSE. *
10 * For the list of contributors see $ROOTSYS/README/CREDITS. *
11 *************************************************************************/
12#ifndef ROOT_R_TRInternalFunction
13#define ROOT_R_TRInternalFunction
14
15#include <RExports.h>
16
17//________________________________________________________________________________________________________
18/**
19 This is a class to support deprecated method to pass function to R's Environment,
20 based in Rcpp::InternalFunction
21
22
23 @ingroup R
24*/
25
26
27namespace Rcpp {
29 {
30public:
31
32 RCPP_GENERATE_CTOR_ASSIGN(TRInternalFunction_Impl)
33
34#include <TRInternalFunction__ctors.h>
35 void update(SEXP) {}
36private:
37
38 inline void set(SEXP xp) {
39 Rcpp::Environment RCPP = Rcpp::Environment::Rcpp_namespace() ;
40 Rcpp::Function intf = RCPP["internal_function"] ;
41 Storage::set__(intf(xp)) ;
42 }
43
44 };
45
46
47}
48
49
50namespace ROOT {
51 namespace R {
52
53 typedef Rcpp::TRInternalFunction_Impl<Rcpp::PreserveStorage> TRInternalFunction ;
54 }
55}
56
57#endif
static void update(gsl_integration_workspace *workspace, double a1, double b1, double area1, double error1, double a2, double b2, double area2, double error2)
TRInternalFunction_Impl(OUT(*fun)(void))
Double_t(* Function)(Double_t)
Definition: Functor.C:4
Rcpp::TRInternalFunction_Impl< Rcpp::PreserveStorage > TRInternalFunction
This file contains a specialised ROOT message handler to test for diagnostic in unit tests.
This is a class to support deprecated method to pass function to R's Environment, based in Rcpp::Inte...
Definition: RExports.h:79
RCPP_API_CLASS(TRInternalFunction_Impl)