final List<Element> databaseRepositories = XmlUtils.findElements(
jdbcDatabase.getConfigPrefix() + "/repositories/repository",
configuration);
for (final Element repositoryElement : databaseRepositories) {
repositories.add(new Repository(repositoryElement));
}
final List<Element> ormRepositories = XmlUtils.findElements(
ormProvider.getConfigPrefix() + "/repositories/repository",
configuration);
for (final Element repositoryElement : ormRepositories) {
repositories.add(new Repository(repositoryElement));
}
final List<Element> jpaRepositories = XmlUtils
.findElements(
"/configuration/persistence/provider[@id='JPA']/repositories/repository",
configuration);
for (final Element repositoryElement : jpaRepositories) {
repositories.add(new Repository(repositoryElement));
}
// Add all new repositories to pom.xml
projectOperations.addRepositories(moduleName, repositories);
}