Class ELFunctionBinder
java.lang.Object
io.micronaut.el.processor.compiler.ELFunctionBinder
Binds the functions a class declares to their qualified names.
- Since:
- 1.0
- Author:
- Denis Stepanov
-
Method Summary
Modifier and TypeMethodDescriptionstatic voidbind(io.micronaut.inject.ast.ClassElement type, String defaultPrefix, boolean onlyAnnotated, Map<String, io.micronaut.inject.ast.MethodElement> into) Binds the functions of a class: its public static methods, the public instance methods it declares, and the@JvmStaticfunctions of its Kotlin companion object.static booleandeclaresFunctions(io.micronaut.inject.ast.ClassElement type)
-
Method Details
-
bind
public static void bind(io.micronaut.inject.ast.ClassElement type, String defaultPrefix, boolean onlyAnnotated, Map<String, io.micronaut.inject.ast.MethodElement> into) Binds the functions of a class: its public static methods, the public instance methods it declares, and the@JvmStaticfunctions of its Kotlin companion object. Once a method of the class is annotated withELFunction, only the annotated methods are functions.- Parameters:
type- The classdefaultPrefix- The prefix of the functions that declare noneonlyAnnotated- Whether only the methods annotated withELFunctionare boundinto- The functions, by qualified name
-
declaresFunctions
public static boolean declaresFunctions(io.micronaut.inject.ast.ClassElement type) - Parameters:
type- The class- Returns:
- Whether the class declares a function with
ELFunction, on a method of its own or of its Kotlin companion object
-