1 // Created on: 1996-04-18
2 // Created by: Joelle CHAUVET
3 // Copyright (c) 1996-1999 Matra Datavision
4 // Copyright (c) 1999-2014 OPEN CASCADE SAS
6 // This file is part of Open CASCADE Technology software library.
8 // This library is free software; you can redistribute it and/or modify it under
9 // the terms of the GNU Lesser General Public License version 2.1 as published
10 // by the Free Software Foundation, with special exception defined in the file
11 // OCCT_LGPL_EXCEPTION.txt. Consult the file LICENSE_LGPL_21.txt included in OCCT
12 // distribution for complete text of the license and disclaimer of any warranty.
14 // Alternatively, this file may be used under the terms of Open CASCADE
15 // commercial license or contractual agreement.
17 #ifndef AdvApp2Var_EvaluatorFunc2Var_HeaderFile
18 #define AdvApp2Var_EvaluatorFunc2Var_HeaderFile
20 #include <Standard_Integer.hxx>
21 #include <Standard_Real.hxx>
22 #include <Standard_PrimitiveTypes.hxx>
24 // History - the C function pointer converted to a virtual class
25 // in order to get rid of usage of static functions and static data
26 class AdvApp2Var_EvaluatorFunc2Var
31 AdvApp2Var_EvaluatorFunc2Var() {}
33 //! Destructor should be declared as virtual
34 virtual ~AdvApp2Var_EvaluatorFunc2Var () {}
36 //! Function evaluation method to be defined by descendant
37 virtual void Evaluate (Standard_Integer* theDimension,
38 Standard_Real* theUStartEnd, //!< First and last parameters in U
39 Standard_Real* theVStartEnd, //!< First and last parameters in V
40 Standard_Integer* theFavorIso, //!< Choice of constante, 1 for U, 2 for V
41 Standard_Real* theConstParam, //!< Value of constant parameter
42 Standard_Integer* theNbParams, //!< Number of parameters N
43 Standard_Real* theParameters, //!< Values of parameters,
44 Standard_Integer* theUOrder, //!< Derivative Request in U
45 Standard_Integer* theVOrder, //!< Derivative Request in V
46 Standard_Real* theResult, //!< Result[Dimension,N]
47 Standard_Integer* theErrorCode) const = 0;
49 //! Shortcut for function-call style usage
50 void operator() (Standard_Integer* theDimension,
51 Standard_Real* theUStartEnd,
52 Standard_Real* theVStartEnd,
53 Standard_Integer* theFavorIso,
54 Standard_Real* theConstParam,
55 Standard_Integer* theNbParams,
56 Standard_Real* theParameters,
57 Standard_Integer* theUOrder,
58 Standard_Integer* theVOrder,
59 Standard_Real* theResult,
60 Standard_Integer* theErrorCode) const
62 Evaluate (theDimension, theUStartEnd, theVStartEnd, theFavorIso,
63 theConstParam, theNbParams,
64 theParameters, theUOrder, theVOrder, theResult, theErrorCode);
69 //! Copy constructor is declared private to forbid copying
70 AdvApp2Var_EvaluatorFunc2Var (const AdvApp2Var_EvaluatorFunc2Var& ) {}
72 //! Assignment operator is declared private to forbid copying
73 void operator= (const AdvApp2Var_EvaluatorFunc2Var& ) {}