Activate Java

As an example, we use a Java demo project consisting of:

  1. an empty Java-Package lfet.demo

  2. a matching resource directory con­tai­ning the deci­sion ta­ble InvoiceTotal

    activate 02

The deci­sion ta­ble is – and remains – purely functional, i.e. it does not contain any technical infor­mation regar­ding the desired Java gene­ra­tion.

In this sta­tus, Java gene­ra­tion is not yet available for the project. This can be recognized, for example, by the fact that the ge­ne­ra­te icon generate 21x21 is missing in the symbol bar:

index 02
 

One-time activation of Java in resources/lfet

In order to activate gene­ra­tion of Java for all deci­sion ta­bles in the direc­tory hierarchy of resources/lfet/, a new confi­gu­ra­tion file lfet.project.yaml is created in the resources/lfet/ direc­tory:

index 03

The new resources/lfet/lfet.project.yaml file initially contains only entry 1) and 2):
lfet:                    # 1)

  ide:
    default: java        # 2)

Entries in detail:

1)  lfet:

The base entry in all YAML confi­gura­tion files for LF‑ET.

2)  ide:
       default: java

Java is activated for all deci­sion ta­bles in and under the resources/lfet/ direc­tory.

Generation is still failing

Though Java gene­ra­tion is now available for the project, once it is started,

gensrc menu 02 java

it still terminates with an error message since it has not been configured that the recom­men­ded Ge­ne­ra­tion Vari­ant 1 (Interface and Rules Module) should be used:

activate 01
 

The fastest way to start program gene­ra­tion is to use the key­board short­cut CTRL+G