Search in sources :

Example 1 with Builder

use of org.apache.camel.language.csimple.CSimpleLanguage.Builder in project camel-quarkus by apache.

the class CSimpleProcessor method configureCSimpleLanguage.

@Record(ExecutionTime.STATIC_INIT)
@BuildStep
@Consume(CamelContextBuildItem.class)
CamelBeanBuildItem configureCSimpleLanguage(RecorderContext recorderContext, CSimpleLanguageRecorder recorder, List<CompiledCSimpleExpressionBuildItem> compiledCSimpleExpressions) {
    final RuntimeValue<Builder> builder = recorder.csimpleLanguageBuilder();
    for (CompiledCSimpleExpressionBuildItem expr : compiledCSimpleExpressions) {
        recorder.addExpression(builder, recorderContext.newInstance(expr.getClassName()));
    }
    final RuntimeValue<?> csimpleLanguage = recorder.buildCSimpleLanguage(builder);
    return new CamelBeanBuildItem("csimple", CSimpleLanguage.class.getName(), csimpleLanguage);
}
Also used : CSimpleLanguage(org.apache.camel.language.csimple.CSimpleLanguage) CamelBeanBuildItem(org.apache.camel.quarkus.core.deployment.spi.CamelBeanBuildItem) RouteBuilder(org.apache.camel.builder.RouteBuilder) Builder(org.apache.camel.language.csimple.CSimpleLanguage.Builder) CompiledCSimpleExpressionBuildItem(org.apache.camel.quarkus.core.deployment.spi.CompiledCSimpleExpressionBuildItem) Consume(io.quarkus.deployment.annotations.Consume) Record(io.quarkus.deployment.annotations.Record) BuildStep(io.quarkus.deployment.annotations.BuildStep)

Aggregations

BuildStep (io.quarkus.deployment.annotations.BuildStep)1 Consume (io.quarkus.deployment.annotations.Consume)1 Record (io.quarkus.deployment.annotations.Record)1 RouteBuilder (org.apache.camel.builder.RouteBuilder)1 CSimpleLanguage (org.apache.camel.language.csimple.CSimpleLanguage)1 Builder (org.apache.camel.language.csimple.CSimpleLanguage.Builder)1 CamelBeanBuildItem (org.apache.camel.quarkus.core.deployment.spi.CamelBeanBuildItem)1 CompiledCSimpleExpressionBuildItem (org.apache.camel.quarkus.core.deployment.spi.CompiledCSimpleExpressionBuildItem)1