With Command you can launch command (Ant target, Maven goal,...) with Eclipse wizard page to build/generate project (WEB, Struts,...). Command is defined into output of XML component and can launch for instance target of Ant build.xml file.

XUL controls value can be used into command properties.


XML command element defined into output of XML component describe command to launch. The following sample is able to launch command (Ant target) name_of_myCommand defined into path_of_myCommandConfig configuration file :

<?xml version="1.0" encoding="UTF-8"?>
      <command type="ant" 
               name="name_of_myCommand" />

Command Attributs

Attribute nameDescriptionRequired ?
typeCommand engine type (Ant, Maven,...). By default type="ant" is used.No
uriURI of configuration file of commands to use. With Ant, uri is the path of the build.xmlNo
pathPath of configuration file of commands to use. See path section.No
nameCommande name to launch. With Ant, name is the target to launch.Yes
conditionCall javascript fonction which return true if command must be launched and false otherwiseNo

Command declaration (used into output of XML component) which must launch name_of_myCommand command defined into configuration file path_of_myCommandConfig is done with command element :

  <command uri="path_of_myCommandConfig" name="name_of_myCommand"  />

path_of_myCommandConfig is the path of configuration file of command. More exactly path_of_myCommandConfig is the uri of the configuration command file. All cmmands must be stored into Commands folder of the catalog. Command uri must start with this folder.

  <command type="ant" uri="/ant/build.xml" name="myTarget" />

means there is /ant/build.xml file stored into Commands folder of catalogue. Ant target to launch is myTarget.

You can use path to use ant/build.xml file :

  <command type="ant" path="catalog:/Commands/ant/build.xml" name="myTarget" />

Command engine

Command engine are getted with Spring descriptor. By default, Akrogen implements command engine :

  • Ant getted with ant ID.
  • Maven getted with maven ID. Maven is not supported today.