Example: Adding a Generation Option

In this example, we will add a generation option to the Java object language.

  1. Select Language > Edit Current Object Language to open the Java resource file.
  2. Expand the Generation category, and then right-click the Options category and select New:


  3. Click OK to save your changes and return to the model. Then select Language > Generate Java code to open the Generation dialog, and click the Options tab. The new option is listed on the tab under its comment (or its name, if no comment has been provided):


    Note: For detailed information about creating and modifying generation templates, see Customizing Generation with GTL.