Changeset 3098 in Sophya for trunk/SophyaLib/NTools/classfunc.h


Ignore:
Timestamp:
Nov 2, 2006, 3:32:37 PM (19 years ago)
Author:
ansari
Message:

correction bug lie au delete de ClassFunc ds Integrator / petite amelioration interface Integrator - Reza 02/11/2006

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/SophyaLib/NTools/classfunc.h

    r2283 r3098  
    1010namespace SOPHYA {
    1111
    12 //abstract class-function
     12//! Abstract interface definition for functions (double f(double)) viewed as classes
    1313class ClassFunc {
    1414public:
    15   virtual double operator()(double x)=0;
     15  virtual double operator()(double x) const =0;
    1616};
    1717
     
    2222 public:
    2323  Function(double (*g)(double)):f(g){}
    24   inline  double operator()(double x){ return f(x);}
     24  virtual  double operator()(double x) const { return f(x);}
    2525};
    2626
Note: See TracChangeset for help on using the changeset viewer.