private void processFile(String filename, File srcFile, boolean isAbsolute) throws IOException { String src = ResourceGroovyMethods.getText(srcFile); String relPackage = tool.getPath(filename).replace('\\', FS); String packagePath = isAbsolute ? "DefaultPackage" : relPackage; String file = tool.getFile(filename);
String src = DefaultGroovyMethods.getText(new File(srcFileName)); String packagePath = tool.getPath(filename); packagePath = packagePath.replace('\\', FS); String file = tool.getFile(filename);
private void processFile(String filename, File srcFile) throws IOException { String src = DefaultGroovyMethods.getText(srcFile); String packagePath = tool.getPath(filename).replace('\\', FS); String file = tool.getFile(filename); SimpleGroovyPackageDoc packageDoc = (SimpleGroovyPackageDoc) rootDoc.packageNamed(packagePath); if (packageDoc == null) { packageDoc = new SimpleGroovyPackageDoc(packagePath); } if (filename.endsWith("package.html") || filename.endsWith("package-info.java") || filename.endsWith("package-info.groovy")) { processPackageInfo(src, filename, packageDoc); rootDoc.put(packagePath, packageDoc); return; } try { Map<String, GroovyClassDoc> classDocs = getClassDocsFromSingleSource(packagePath, file, src); rootDoc.putAllClasses(classDocs); packageDoc.putAll(classDocs); rootDoc.put(packagePath, packageDoc); } catch (RecognitionException e) { System.err.println("ignored due to RecognitionException: " + filename + " [" + e.getMessage() + "]"); } catch (TokenStreamException e) { System.err.println("ignored due to TokenStreamException: " + filename + " [" + e.getMessage() + "]"); } }
private void processFile(String filename, File srcFile) throws IOException { String src = DefaultGroovyMethods.getText(srcFile); String packagePath = tool.getPath(filename).replace('\\', FS); String file = tool.getFile(filename); SimpleGroovyPackageDoc packageDoc = (SimpleGroovyPackageDoc) rootDoc.packageNamed(packagePath); if (packageDoc == null) { packageDoc = new SimpleGroovyPackageDoc(packagePath); } if (filename.endsWith("package.html")) { processHtmlPackage(src, packageDoc); return; } try { Map<String, GroovyClassDoc> classDocs = getClassDocsFromSingleSource(packagePath, file, src); rootDoc.putAllClasses(classDocs); packageDoc.putAll(classDocs); rootDoc.put(packagePath, packageDoc); } catch (RecognitionException e) { System.err.println("ignored due to RecognitionException: " + filename + " [" + e.getMessage() + "]"); } catch (TokenStreamException e) { System.err.println("ignored due to TokenStreamException: " + filename + " [" + e.getMessage() + "]"); } }
private void processFile(String filename, File srcFile, boolean isAbsolute) throws IOException { String src = ResourceGroovyMethods.getText(srcFile); String relPackage = tool.getPath(filename).replace('\\', FS); String packagePath = isAbsolute ? "DefaultPackage" : relPackage; String file = tool.getFile(filename);
private void processFile(String filename, File srcFile, boolean isAbsolute) throws IOException { String src = DefaultGroovyMethods.getText(srcFile); String packagePath = isAbsolute ? "DefaultPackage" : tool.getPath(filename).replace('\\', FS); String file = tool.getFile(filename); SimpleGroovyPackageDoc packageDoc = null;