Interface ExpressionFunctionProvider
-
- All Superinterfaces:
org.pf4j.ExtensionPoint,com.netflix.spinnaker.kork.plugins.api.internal.SpinnakerExtensionPoint
public interface ExpressionFunctionProvider extends com.netflix.spinnaker.kork.plugins.api.internal.SpinnakerExtensionPointProvides a contract for adding new function definitions for SpEL evaluation.The SpEL expression evaluator expects the the function implementations are included in the same concrete class as the
ExpressionFunctionProvider, with method names matching those defined in thegetFunctions()definitions.{@code class HelloFunctionProvider : ExpressionFunctionProvider { override fun getNamespace(): String? = "netflix" override fun getFunctions(): Functions = Functions( "hello", FunctionParameter( Execution::class.java, "execution", "The pipeline execution object that this function is being invoked on" ) )
-
-
Nested Class Summary
Nested Classes Modifier and Type Interface Description static classExpressionFunctionProvider.FunctionDefinitionA single function definition.static classExpressionFunctionProvider.FunctionDocumentationDocumentation for a function.static classExpressionFunctionProvider.FunctionParameterThe definition of a single function parameter.static classExpressionFunctionProvider.FunctionsA wrapper for a collection ofExpressionFunctionProvider.FunctionDefinitionobjects.static classExpressionFunctionProvider.FunctionUsageExampleFunction usage example.
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description ExpressionFunctionProvider.FunctionsgetFunctions()A collection ofExpressionFunctionProvider.FunctionDefinitions.java.lang.StringgetNamespace()Optional.
-
-
-
Method Detail
-
getNamespace
@Nullable java.lang.String getNamespace()
Optional. Typically, a namespace should be provided if you are providing a non-core function. The namespace value typically would be the name of your organization (e.g.netflixormyteamname.
-
getFunctions
ExpressionFunctionProvider.Functions getFunctions()
A collection ofExpressionFunctionProvider.FunctionDefinitions.
-
-