/* Code to print the active Apache file list */
String rootConfFile = "/usr/local/apache2/conf/httpd.conf";
String serverRoot = "/usr/local/apache2";
String binFile = "/usr/local/apache2/bin/apachectl";
StaticModuleParser staticParser = new StaticModuleParser(new File(binFile));
SharedModuleParser sharedParser = new SharedModuleParser(new File(binFile));
Parser parser = new Parser(rootConfFile, serverRoot, staticParser.getStaticModules(), sharedParser.getSharedModules());
String files[] = parser.getActiveConfFileList();
for(int i=0; i<files.length; i++) {
System.out.println(files[i]);
}