The code generation template set

Genero Studio provides a standard template set of files that are used for code generation. The files are written in XML and Tcl.


This figure is a flow diagram BA Diagrams flowing to XML files flowing to Code Generation Engine flowing to 4gl Application code. Tcl, XSL, and Python templates are also input into the Code Generation Engine.

Figure 1. Code Generation flow

Default templates

Table 1. Application Generation Templates
Template Description
dbapp3.1 This is the default and recommended template for 2.51.
dbapp3.0 This is the default and recommended template for 2.50.
dbapp2.0 This is the default and recommended template for 2.41.
dbapp1.0 The dbapp template in Genero Studio 2.40 was renamed in Genero Studio 2.41 to  dbapp1.0. The  dbapp  template set is the same template set as  dbapp1.0. This is the default and recommended template for 2.40. Using the DIALOG instruction, sub-dialog statements that display data, query a database, and edit single records and record lists can execute in parallel, allowing the application to handle different parts of a form simultaneously.
2.3x This is a legacy template for compatibility with applications developed with Genero Studio 2.3x.
The GSTSETUPDIR environment variable specifies which template set is used.

Template directory contents

GSTDIR/bin/src/ag/tpl/... includes:
  • settings.agconf
  • creatables.conf
  • file-types.xml
  • build.rules
  • *.tcl
  • resource/*/*
    Note: It is recommended that you not modify the original template files, but make a copy of the directory. Copy the entire content of the GSTDIR/gst/bin/src/ag/tpl/dbapp directory to a new directory. The new template directory could be a common one on the server or it could be part of the entire versioned project.