List of usage examples for org.eclipse.jdt.internal.core SourceType getJavadocRange
@Override
public ISourceRange getJavadocRange() throws JavaModelException
From source file:hydrograph.ui.expression.editor.datastructure.ClassDetails.java
License:Apache License
private String getJavaDoc(SourceType javaClassFile) throws JavaModelException { StringBuffer source = new StringBuffer(javaClassFile.getSource()); try {//from w w w . j ava 2s. com String javaDoc = StringUtils.substring(source.toString(), 0, javaClassFile.getJavadocRange().getLength()); javaDoc = StringUtils.replaceEachRepeatedly(javaDoc, new String[] { "/*", "*/", "*" }, new String[] { Constants.EMPTY_STRING, Constants.EMPTY_STRING, Constants.EMPTY_STRING }); } catch (Exception exception) { LOGGER.warn("Failed to build java-doc for :{}", javaClassFile); } return javaDoc; }