return style;
}
private void genStyled(File cache, String organisation, String module, String[] confs,
File style, String ext) throws IOException {
ResolutionCacheManager cacheMgr = getIvyInstance().getCacheManager(cache);
// process the report with xslt to generate dot file
File out;
if (todir != null) {
out = todir;
} else {
out = new File(".");
}
InputStream xsltStream = null;
try {
// create stream to stylesheet
xsltStream = new BufferedInputStream(new FileInputStream(style));
Source xsltSource = new StreamSource(xsltStream, JAXPUtils.getSystemId(style));
// create transformer
TransformerFactory tFactory = TransformerFactory.newInstance();
Transformer transformer = tFactory.newTransformer(xsltSource);
// add standard parameters
transformer.setParameter("confs", conf);
transformer.setParameter("extension", xslext);
// add the provided XSLT parameters
for (Iterator it = params.iterator(); it.hasNext();) {
XSLTProcess.Param param = (XSLTProcess.Param) it.next();
transformer.setParameter(param.getName(), param.getExpression());
}
// create the report
for (int i = 0; i < confs.length; i++) {
File reportFile =
cacheMgr.getConfigurationResolveReportInCache(resolveId, confs[i]);
File outFile =
new File(out, IvyPatternHelper.substitute(outputpattern, organisation, module,
"", "", "", ext, confs[i]));
log("Processing " + reportFile + " to " + outFile);