DialectType dType = factory.createDialectType();
dType.setType(dbType.name());
for (Procedure proc : sorted) {
if (proc.getStatments().isEmpty()) continue;
ProcedureType pType = factory.createProcedureType();
pType.setName(proc.getProcedureName());
for (Entry<String, SQLStmt> e : proc.getStatments().entrySet()) {
StatementType sType = factory.createStatementType();
sType.setName(e.getKey());
sType.setValue(e.getValue().getOriginalSQL());
pType.getStatement().add(sType);
} // FOR (stmt)
dType.getProcedure().add(pType);
} // FOR
DialectsType dialects = factory.createDialectsType();
dialects.getDialect().add(dType);