propsToUse.putAll(userProperties);
getLog().info("Using Properties: " + propsToUse);
Tool t = new Tool();
GenericXmlApplicationContext context = t.createSpringContext(propsToUse, this.getClass().getClassLoader());
BasicKite9Runner runner = (BasicKite9Runner) context.getBean(BasicKite9Runner.class);
Kite9Context kite9Context = (Kite9Context) context.getBean(Kite9Context.class);
boolean addMap = new File(propsToUse.getProperty("javadoc-listener.docRoot")).exists();
final Map<String, WorkItem> toInclude = new LinkedHashMap<String, WorkItem>();
runner.getListeners().add(new BuildListener() {
public boolean canProcess(WorkItem designItem) {
return true;
}
public void finished() {
}
public void process(WorkItem designItem) throws Exception {
toInclude.put(prepareCaption(designItem), designItem);
}
});
runner.process();
try {
createReport(getSink(), toInclude, kite9Context, addMap);
} catch (IOException e) {
throw new MavenReportException("Could not generate maven kite9 report: ", e);