This repository generates JAXB and Transport resources for the OpenRoberta lab. These resources change almost never. So this project is seldom used.
-
the OpenRoberta lab reads XML generated by blockly and creates an AST for further code generation. This process is facilitated by using jaxb2 to create a Java bean tree matching the XML tree. Actual Java has removed jaxb support (xjc, parts in rt.jar). Thus this project uses the ancient Java 8 for a stable build of the Java source classes.
- after a change in the xsd found at
src/main/resources/blockly.xsd
- the Java bean tree has to be (re-)generated (this are Java source classes) by executing
mvn clean install
and - then use the "organize import"-function of your IDE for the whole directory
src/main/java/de/fhg/iais/roberta/blockly/generated
and - copy all files manually from
src/main/java/de/fhg/iais/roberta/blockly/generated
to the openroberta-lab projectOpenRobertaRobot
into the same package.
- after a change in the xsd found at
-
the OpenRoberta lab front end (written in typescript) and the back end (written in Java) communicate using POST commands in the style of REST. The payload of the POSTs are JSON objects. To reduce the amount of errors when these JSON objects are constructed, sent and destructed, the maven plugin
de.fhg.iais.tools:TransportGenerator:16.0.0
found in the maven repository athttps://maven.iais.fraunhofer.de/artifactory/openroberta-release
is used as the bean generator. The definitions of all the JSON objects are found in the resourcerestEntities.json
.- after a change in the resource
src/main/resources/restEntities.json
- the Javas have to be (re-)generated (this are Java source classes) by executing
mvn clean install
and - then use the "organize import"-function of your IDE for the whole directory
src/main/java/de/fhg/iais/roberta/generated/restEntities
and - copy all files manually from
src/main/java/de/fhg/iais/roberta/generated/restEntities
to the openroberta-lab projectOpenRobertaServer
into the same package.
- after a change in the resource
If you are an open source developer and like to design a better solution to this please contact reinhard.budde at iais.fraunhofer.de