try {
if (xsds.isEmpty()) {
log.warn("No xsd's selected for generation.");
}
final CodeGenerator readerGenerator = new ReaderGenerator("com.bla.bla", new FileOutputStreamFactory(sourceGenerationDirectory));
final CodeGenerator gatherMapperGenerator = new MapperTemplateGenerator("com.bla.bla", new FileOutputStreamFactory(sourceGenerationDirectory));
final CodeGenerator immutableModelMapperGenerator = new ImmutableModelMapperGenerator("com.bla.bla", new FileOutputStreamFactory(sourceGenerationDirectory));
final CodeGenerator immutableModelGenerator = new ImmutableModelGenerator("com.bla.bla", new FileOutputStreamFactory(sourceGenerationDirectory));
// final CodeGenerator mutableModelMapperGenerator = new MutableModelMapperGenerator("com.bla.bla", new FileOutputStreamFactory(sourceGenerationDirectory));
final SampleXmlGenerator sampleXmlGenerator = new SampleXmlGenerator(new FileOutputStreamFactory(sourceGenerationDirectory));
final XSLoader schemaLoader = xsdReader.createSchemaLoader();
final ModelTransformer modelTransformer = new ModelTransformer();
for (String xsd : xsds) {
log.info("Processing: {}", xsd);
final XSModel xsModel = schemaLoader.loadURI(new File(schemaDirectory, xsd).toURI().toString());
Schema schema = xsdReader.readXsd(xsd, xsModel);
final Model model = modelTransformer.transform(schema);
readerGenerator.generate(model);
gatherMapperGenerator.generate(model);
immutableModelGenerator.generate(model);
immutableModelMapperGenerator.generate(model);
sampleXmlGenerator.writeSample(schema);
}
} catch (Exception e) {