Last change
on this file since 3120 was 3115, checked in by ansari, 19 years ago |
Creation initiale du groupe Cosmo avec le repertoire SimLSS de
simulation de distribution de masse 3D des galaxies par CMV+Rz
18/12/2006
|
File size:
1.1 KB
|
Line | |
---|
1 | #ifndef GENERICFUNC_H
|
---|
2 | #define GENERICFUNC_H
|
---|
3 |
|
---|
4 | #include "pexceptions.h"
|
---|
5 |
|
---|
6 | namespace SOPHYA {
|
---|
7 |
|
---|
8 | //! Abstract interface definition for functions (double f(double)) viewed as classes
|
---|
9 | class GenericFunc {
|
---|
10 | public:
|
---|
11 | GenericFunc(void) { }
|
---|
12 | virtual ~GenericFunc(void) { }
|
---|
13 |
|
---|
14 | virtual double operator()(double x) {
|
---|
15 | cout<<"GenericFunc::operator(double) not implemented"<<endl;
|
---|
16 | throw NotAvailableOperation("GenericFunc::operator(double) not implemented");
|
---|
17 | }
|
---|
18 |
|
---|
19 | virtual double operator()(double x,double y) {
|
---|
20 | cout<<"GenericFunc::operator(double,double) not implemented"<<endl;
|
---|
21 | throw NotAvailableOperation("GenericFunc::operator(double,double) not implemented");
|
---|
22 | }
|
---|
23 |
|
---|
24 | virtual double operator()(double x,double y,double z) {
|
---|
25 | cout<<"GenericFunc::operator(double,double,double) not implemented"<<endl;
|
---|
26 | throw NotAvailableOperation("GenericFunc::operator(double,double,double) not implemented");
|
---|
27 | }
|
---|
28 |
|
---|
29 | virtual double operator()(double* x) {
|
---|
30 | cout<<"GenericFunc::operator(double*) not implemented"<<endl;
|
---|
31 | throw NotAvailableOperation("GenericFunc::operator(double*) not implemented");
|
---|
32 | }
|
---|
33 |
|
---|
34 | };
|
---|
35 |
|
---|
36 | }
|
---|
37 |
|
---|
38 | #endif
|
---|
Note:
See
TracBrowser
for help on using the repository browser.