Build Configuration

Support questions relating to project setup, BuildConfig, code generator, etc.

Build Configuration

Postby micha » Wed Jun 15, 2011 12:56 pm

Actifsource has a sophisticated build configuration system which controls what templates and what model elements are used to generate code into actifsource projects. This system consists of the BuildConfig with the BuildTasks and the project's Target Folders.

BuildConfig
The BuildConfig is a element of the actifsource Core Model which allows to group a set of templates and set some basic configurations. Instances of BuildConfig are usually created in the project where the templates are located. The properties of the BuildConfig are:
  • name: Identifier for the BuildConfig
  • outputEncoding: Defines the encoding of the generated files.
  • lineBreak: Defines the character sequence for line breaks in the generated files (as on the Mac, Unix or Windows platform).
  • buildTask: A list of BuildTasks.
  • commentStartTag: The start tag of a comment in the generated files. Defaults to "/*"
  • commentStartTag: The end tag of a comment in the generated files. Defaults to "*/"

BuildTask
BuildTask is the base class of all build task. There are different build tasks for different template languages. (In the community edition only actifsource templates are supported, in the enterprise edition there is support for xPand and freemarker as well.)

TemplateGeneratorTask
References an actifsource template which is included in this BuildConfig. A template can be used in multiple BuildConfigs. The only additional setting in the TemplateGeneratorTask is the omitFileId which can be set to true if no file id should be generated into the output files by this template. This can be neccessary when the output file does not support any comments. As a consequence, these files do not get automatically renamed and removed.

Target Folder
A project can have one or more target folders. Target folders are folders into which files are generated. A target folder references one or more BuildConfigs which should be applied to the folder. Additionally, for each BuildConfig, a set of packages and resources can be chosen for which the templates references in the BuildConfig should be generated.

If there is no BuildConfig defined for a target folder, then all templates in the project and all resources in the project are used to generate. This is a default setting to make the initial configuration easier.
micha
 
Posts: 21
Joined: Thu Aug 05, 2010 2:41 pm
Location: Switzerland

Re: Build Configuration

Postby GiUmaTo » Wed Jun 15, 2011 11:33 pm

Quite a good explanation. In the meantime I've done some trial and error too.

Thanks for your time!
GiUmaTo
 
Posts: 10
Joined: Thu Jun 09, 2011 11:21 pm


Return to Environment

Who is online

Users browsing this forum: No registered users and 1 guest

cron