//listener.setReportFile(*something*);
cocoon.setFollowLinks(true);
cocoon.setConfirmExtensions(false);
//cocoon.addLoadedClasses(Arrays.asList(*something*));
//cocoon.addTargets(BeanConfigurator.processURIFile(*some file*), destDir);
cocoon.addListener(new OutputStreamListener(System.out));
cocoon.initialize();
return cocoon;
}