{
setUp();
GeneratorLogger logger = new MavenGeneratorLogger( getLog() );
GenerationRequest request = new GenerationRequest();
request.setClasses( getFilesToGenerator() );
request.setClassLoader( this.initializeClassLoader() );
request.setExtraOptions( extraOptions );
request.setPersistentOutputFolder( outputDirectory );
request.setTemplates( templates );
request.setTransientOutputFolder( baseOutputDirectory );
request.setTranslators( translators );
request.setLogger( logger );
ClassLoader cl = currentThread().getContextClassLoader();
try
{
currentThread().setContextClassLoader( request.getClassLoader() );
Generator generator = generatorFactory.getGenerator( generatorToUse );
generator.generate( request );
}
catch ( GenerationException e )