public static String generateInheritanceTree(String cp) throws IOException { LoggingUtils.getEvoLogger().info("* Analyzing classpath (generating inheritance tree)"); List<String> cpList = Arrays.asList(cp.split(File.pathSeparator)); // Clear current inheritance file to make sure a new one is generated Properties.INHERITANCE_FILE = ""; InheritanceTree tree = InheritanceTreeGenerator.createFromClassPath(cpList); File outputFile = File.createTempFile("ES_inheritancetree", ".xml.gz"); outputFile.deleteOnExit(); InheritanceTreeGenerator.writeInheritanceTree(tree, outputFile); return outputFile.getAbsolutePath(); }
private static void initInheritanceTree(List<String> classPath) { logger.debug("Calculate inheritance hierarchy"); inheritanceTree = InheritanceTreeGenerator.createFromClassPath(classPath); TestClusterGenerator clusterGenerator = new TestClusterGenerator(inheritanceTree); TestGenerationContext.getInstance().setTestClusterGenerator(clusterGenerator); InheritanceTreeGenerator.gatherStatistics(inheritanceTree); }