Rcpp Version 1.0.14
Loading...
Searching...
No Matches
convolve10_cpp.h
Go to the documentation of this file.
1
2class Cache{
3public:
4 typedef double& proxy ;
5 typedef double* iterator ;
6
7 Cache( iterator data_) : data(data_){}
8
9 inline proxy ref(int i){ return data[i] ; }
10 inline proxy ref(int i) const { return data[i] ; }
11
12private:
14} ;
15
16class Vec {
17public:
18 typedef double& proxy ;
19
20 Vec( double* data_ ) : cache(data_){}
21 inline proxy operator[]( int i){ return cache.ref(i) ; }
22 inline proxy operator[]( int i) const { return cache.ref(i) ; }
23
24private:
26} ;
27
Cache(iterator data_)
proxy ref(int i) const
proxy ref(int i)
iterator data
double * iterator
double & proxy
proxy operator[](int i) const
Vec(double *data_)
proxy operator[](int i)
double & proxy
Cache cache