conversionOptions.setShowLineNumbers(numbered);
JavaSourceConversionSettings settings = new JavaSourceConversionSettings(conversionOptions) {
@Override
public IJavaSourceConverter createConverter() {
return new JavaSource2Xhtml11Converter();
}
};
string = Java2Html.convertToHtml(string, settings);
/* Removing Java2Html comments (we added it on each Sections page) */
string = string.replaceAll("<!--(.+?)-->\n", "");