Example Programs

Some example programs are provided to show how to use JSDAI. You can find all the example programs in the examples directory.

SdaiTerm

We strongly recommend to try this tool before starting to write your own applications. You can use this program without any knowledge of Java. Most of the SDAI operations are available as 2 character commands. Just type in a sequence of operations and see how JSDAI behaves. Every error condition will be clearly indicated.

ImportExport

Simply imports and then exports a p21-file without making the data persistent. Java source file.

Generating Some AP203 Entities and Exporting them into a p21 File

GenerateExpress

Converting the available dictionary information back to EXPRESS syntax and list it on the screen.
Sources of GenerateExpress.java

Validation

Reads in a p21-file and performs some validation operations. Please, note that only some few validation operations are functioning in this version of JSDAI. A future version of JSDAI will have all validation operations (when full expression evaluation will be available). Please note that this example may fail on instances of some subtype entities which contain explicit attributes of a supertype which are redeclared as derived.
Sources of Validation.java