Import Built-in Templates wizard allows importing of built-in JBuilder templates. To proceed with import the following steps should be completed:
Select Templates to Import Step |
This step allows choosing one or several templates to import. It provides the Templates table that shows all available built-in JBuilder templates and the Code panel that shows preview of a currently selected template code. After choosing desired templates the Next button can be pressed that provides a way to proceed to the next step. Please note, if there are no templates selected the Next button is disabled.
Customize Templates to be Imported Step |
This step allows customizing properties of templates have been selected during the previous step. It provides the Templates table that shows templates to be imported and the Code panel that shows preview of a currently selected template code.
Each template occupies one row in the Templates table while each template' attribute is represented by particular column. The following attributes are shown: Name, Description and Extract Fields.
The Name and Description attributes have initially the same values as ones defined in the built-in template. Any of these attributes can be changed using usual in-place editing capabilities, which provides ability to assign new values for Smart Templates will be created. Certainly this will not affect built-in templates anyway. The Name attribute is marked by the red color if a Smart Template with such name is already exists. All the templates with conflicting names should be properly renamed in order to complete import operation.
The Extract Fields attribute is synthetic one that allows specifying whether all repeating tokens from the template code should be treated as the fields in the imported Smart Templates. This ability can significantly reduce the time and effort needed to make imported templates be Smart ones. The Code panel shows preview of original template code or morphed template code with template fields if this attribute is turned off/on respectively
The Finish button allows starting import operation when the templates customizing is complete. All the imported templates are immediately available in the Templates table of the Smart.Templates property page after import operation completes. As all the imported templates have the same status as ones created manually so to apply changes the Editor Options dialog should be closed by pressing the Ok button. If the Editor Options dialog is closed by pressing the Cancel button all the imported templates will be lost.
See also: Edit Template Dialog, Smart.Templates,