HxmFunctor Interface¶
-
class HxmFunctor¶
External modeler function interface. To use your own external functions in the modeler you have to follow these steps:
Implement this interface with the call method.
Then create a
HxmFunction
withHexalyModeler::createFunction()
.Finally, if you want to make this function available in Hexaly Modeler, you have to assign it to a module variable with
HxmModule::setFunction()
.
Note: This class should only be extended to expose functions used during the modeling process. You should not use this class to create a function that will be called during the resolution as an external function. In this case, you should instead use the optimizer API directly (see
HxExternalFunction
).- See:
- Since:
10.0
Summary¶
The function to call with its arguments. |
|
Default virtual destructor. |
Functions¶
-
virtual HxmValue call(HexalyModeler &modeler, const HxmValue *arguments, int nbArguments) = 0¶
The function to call with its arguments.
- Parameters:
modeler – Modeler instance.
arguments – List of modeler values passed to the function by the caller.
nbArguments – Number of arguments passed to the function by the caller.
- Returns:
Return value of the call.
-
virtual HxmFunctor::~HxmFunctor()¶
Default virtual destructor.