Interface KotlinCodeGenerationProcessor
-
- All Implemented Interfaces:
-
io.toolisticon.kotlin.generation.spi.KotlinCodeGenerationSpi
,java.util.function.BiPredicate
,kotlin.Comparable
public interface KotlinCodeGenerationProcessor<CONTEXT extends KotlinCodeGenerationContext<CONTEXT>, INPUT extends Object, BUILDER extends Object> implements KotlinCodeGenerationSpi<CONTEXT, INPUT>
Root interface of all processors. Used to load all implementations via ServiceLoader/SPI.
-
-
Method Summary
Modifier and Type Method Description abstract BUILDER
invoke(CONTEXT context, INPUT input, BUILDER builder)
Input is nullable because we could use processors solely based on context. BUILDER
execute(CONTEXT context, INPUT input, BUILDER builder)
Checks if this strategy should be applied (using test
) and then runsinvoke
.abstract KClass<CONTEXT>
getContextType()
The type of the generic CONTEXT, used to filter relevant instances. abstract KClass<INPUT>
getInputType()
The type of the generic INPUT, used to filter relevant instances. abstract Integer
getOrder()
Order is used to sort spi instances. abstract String
getName()
abstract KClass<BUILDER>
getBuilderType()
-
Methods inherited from class io.toolisticon.kotlin.generation.spi.KotlinCodeGenerationSpi
compareTo, test
-
Methods inherited from class java.util.function.BiPredicate
and, negate, or
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
-
Method Detail
-
invoke
abstract BUILDER invoke(CONTEXT context, INPUT input, BUILDER builder)
Input is nullable because we could use processors solely based on context.
-
execute
BUILDER execute(CONTEXT context, INPUT input, BUILDER builder)
Checks if this strategy should be applied (using
test
) and then runsinvoke
.
-
getContextType
abstract KClass<CONTEXT> getContextType()
The type of the generic CONTEXT, used to filter relevant instances.
-
getInputType
abstract KClass<INPUT> getInputType()
The type of the generic INPUT, used to filter relevant instances.
-
getBuilderType
abstract KClass<BUILDER> getBuilderType()
-
-
-
-