Is there any API in drools to create the drl files dynamically by just passing values?

前端 未结 6 1749
鱼传尺愫
鱼传尺愫 2021-02-04 12:47

I know how to create DRL files inside KIE workbench by using all the methods. But what my problem is without using the KIE workbench, can we create the .drl fil

6条回答
  •  被撕碎了的回忆
    2021-02-04 13:25

    Another option is to use the "descr" APIs, starting from the factory:

    org.drools.compiler.lang.api.DescrFactory
    

    These APIs build the Drools AST, which can be passed directly to the compiler, bypassing the parser. The AST can also be used to recreate DRL, using the helper class org.drools.compiler.lang.DrlDumper

提交回复
热议问题