Interface EvaluationContextExtension

All Superinterfaces:
ExtensionIdAware

public interface EvaluationContextExtension extends ExtensionIdAware
SPI to allow adding a set of properties and function definitions accessible via the root of an EvaluationContext provided by an ExtensionAwareEvaluationContextProvider.

Extensions can be ordered by following Spring's Ordered conventions.

Since:
1.9
Author:
Thomas Darimont, Oliver Gierke
See Also:
  • Method Details

    • getProperties

      default Map<String,Object> getProperties()
      Return the properties exposed by the extension.
      Returns:
      the properties
    • getFunctions

      default Map<String,Function> getFunctions()
      Return the functions exposed by the extension.
      Returns:
      the functions
    • getRootObject

      @Nullable default Object getRootObject()
      Return the root object to be exposed by the extension. It's strongly recommended to declare the most concrete type possible as return type of the implementation method. This will allow us to obtain the necessary metadata once and not for every evaluation.
      Returns:
      the root object to be exposed by the extension.