* properties
* @return the created ant task instance.
*/
public static AntTask transform( final Properties properties ) {
// This is an old properties file -> transform to EMF/XMI
AntTask task = AntTasksFactory.eINSTANCE.createAntTask();
task.setBuildDirectory( properties.getProperty( MAPPING.get( BUILD_DIRECTORY ) ) );
// TODO extract Manifest entries from properties.
// Deploy
task.setDeploy( AntTasksFactory.eINSTANCE.createDeploy() );
task.getDeploy().setSplashImage( properties.getProperty( MAPPING.get( BUILD_SPLASH_IMAGE ) ) );
// Deploy -> Info
task.getDeploy().setInfo( ParametersFactory.eINSTANCE.createInfo() );
task.getDeploy().getInfo().setVendor( properties.getProperty( MAPPING.get( BUILD_VENDOR_NAME ) ) );
task.getDeploy().setWidth( properties.getProperty( MAPPING.get( DEPLOY_APPLET_WIDTH ) ) );
task.getDeploy().setHeight( properties.getProperty( MAPPING.get( DEPLOY_APPLET_HEIGHT ) ) );
// TODO Webstart Splash
// TODO Webstart Icons
// Deploy -> Application
task.getDeploy().setApplication( ParametersFactory.eINSTANCE.createApplication() );
task.getDeploy().getApplication().setName( properties.getProperty( MAPPING.get( BUILD_APP_TITLE ) ) );
task.getDeploy().getApplication().setVersion( properties.getProperty( MAPPING.get( BUILD_APP_VERSION ) ) );
task.getDeploy().getApplication().setMainclass( properties.getProperty( MAPPING.get( BUILD_APPLICATION_CLASS ) ) );
task.getDeploy().getApplication().setPreloaderclass( properties.getProperty( MAPPING.get( BUILD_PRELOADER_CLASS ) ) );
// SignJar
task.setSignjar( AntTasksFactory.eINSTANCE.createSignJar() );
task.getSignjar().setKeystore( properties.getProperty( MAPPING.get( SIGN_KEYSTORE ) ) );
task.getSignjar().setStorepass( properties.getProperty( MAPPING.get( SIGN_PASSWORD ) ) );
task.getSignjar().setAlias( properties.getProperty( MAPPING.get( SIGN_ALIAS ) ) );
task.getSignjar().setKeypass( properties.getProperty( MAPPING.get( SIGN_KEYPASSWOARD ) ) );
return task;
}