public class FunctionRegistry extends Object
| Modifier and Type | Class and Description |
|---|---|
static class |
FunctionRegistry.ConstructorMeta |
static class |
FunctionRegistry.FunctionMeta |
| Constructor and Description |
|---|
FunctionRegistry() |
| Modifier and Type | Method and Description |
|---|---|
void |
discover(List<String> packages)
Discover and register
HopeFunction implementations that are annotated with FunctionImplementation. |
Optional<FunctionRegistry.FunctionMeta> |
find(String name)
Find a
HopeFunction implementation by name. |
void |
register(Class<? extends HopeFunction> clazz)
Register a
HopeFunction implementation. |
public void discover(List<String> packages)
HopeFunction implementations that are annotated with FunctionImplementation.packages - Extra packages to be scanned besides the standard library.public void register(Class<? extends HopeFunction> clazz)
HopeFunction implementation. Needs to be annotated with FunctionImplementation.clazz - Function class.public Optional<FunctionRegistry.FunctionMeta> find(String name)
HopeFunction implementation by name.name - Name for the function to findCopyright © 2019. All rights reserved.