Class CustomFunctionProvider
- java.lang.Object
-
- org.vedantatree.expressionoasis.extensions.DefaultFunctionProvider
-
- org.vedantatree.expressionoasis.extensions.customfunctions.CustomFunctionProvider
-
- All Implemented Interfaces:
FunctionProvider
public class CustomFunctionProvider extends DefaultFunctionProvider
Provides custom functions where the source code for the functions is stored as configuration in order to make adding new functions very simple.
-
-
Constructor Summary
Constructors Constructor Description CustomFunctionProvider(Class<? extends CustomFunctionSourceProvider> sourceProvider)
Dynamically generates a class at run time based on the source code of methods provided by the sourceProvider, and makes the methods available to the expression engine as functions.
-
Method Summary
-
Methods inherited from class org.vedantatree.expressionoasis.extensions.DefaultFunctionProvider
getFunctionType, getFunctionValue, initialize, supportsFunction
-
-
-
-
Constructor Detail
-
CustomFunctionProvider
public CustomFunctionProvider(Class<? extends CustomFunctionSourceProvider> sourceProvider) throws ExpressionEngineException
Dynamically generates a class at run time based on the source code of methods provided by the sourceProvider, and makes the methods available to the expression engine as functions.- Parameters:
sourceProvider
- class that will provide the source code for the custom functions- Throws:
ExpressionEngineException
InstantiationException
IllegalAccessException
-
-