Interface IFunctionLibrary
-
- All Known Implementing Classes:
DefaultFunctionLibrary
,FunctionLibrary
public interface IFunctionLibrary
-
-
Method Summary
All Methods Instance Methods Abstract Methods Default Methods Modifier and Type Method Description IFunction
getFunction(String name, List<IExpression> arguments)
Retrieve the function with the provided name that supports the signature of the provided methods, if such a function exists.IFunction
getFunction(QName name, List<IExpression> arguments)
Retrieve the function with the provided namespace qualified name that supports the signature of the provided methods, if such a function exists.Stream<IFunction>
getFunctionsAsStream()
Retrieve the collection of function signatures in this library as a stream.default boolean
hasFunction(String name, List<IExpression> arguments)
Determine if there is a function with the provided name that supports the signature of the provided methods.default boolean
hasFunction(QName name, List<IExpression> arguments)
Determine if there is a function with the provided namespace qualified name that supports the signature of the provided methods.
-
-
-
Method Detail
-
getFunctionsAsStream
@NonNull Stream<IFunction> getFunctionsAsStream()
Retrieve the collection of function signatures in this library as a stream.- Returns:
- a stream of function signatures
-
hasFunction
default boolean hasFunction(@NonNull String name, @NonNull List<IExpression> arguments)
Determine if there is a function with the provided name that supports the signature of the provided methods.- Parameters:
name
- the name of a group of functionsarguments
- a list of argument expressions for use in determining an argument signature match- Returns:
true
if a function signature matches orfalse
otherwise
-
hasFunction
default boolean hasFunction(@NonNull QName name, @NonNull List<IExpression> arguments)
Determine if there is a function with the provided namespace qualified name that supports the signature of the provided methods.- Parameters:
name
- the namespace qualified name of a group of functionsarguments
- a list of argument expressions for use in determining an argument signature match- Returns:
true
if a function signature matches orfalse
otherwise
-
getFunction
IFunction getFunction(@NonNull String name, @NonNull List<IExpression> arguments)
Retrieve the function with the provided name that supports the signature of the provided methods, if such a function exists.- Parameters:
name
- the name of a group of functionsarguments
- a list of argument expressions for use in determining an argument signature match- Returns:
- the matching function or
null
if no match exists
-
getFunction
IFunction getFunction(@NonNull QName name, @NonNull List<IExpression> arguments)
Retrieve the function with the provided namespace qualified name that supports the signature of the provided methods, if such a function exists.- Parameters:
name
- the namespace qualified name of a group of functionsarguments
- a list of argument expressions for use in determining an argument signature match- Returns:
- the matching function or
null
if no match exists
-
-