Package org.hl7.fhir.utilities.xhtml
Class XhtmlToMarkdownConverter
java.lang.Object
org.hl7.fhir.utilities.xhtml.XhtmlToMarkdownConverter
Convert XHTML to GFM flavoured markdown
This isn't always possible, but we do our best. The primary issue is that GFM tables cannot be complex - if they contain nested tables, lists, or any other block content, the text format doesn't work There's no much we can do about that, really, so we kid of try to suppress paragraphs but if there is nested content, it'll collapse as a table.
Given that the primary target is AI systems this seems like a workable compromise
The filters are used by the IG publisher to strip out the common template content from the pages
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidconfigureForIGs(boolean processUnknown) voidconvertNode(StringBuilder b, XhtmlNode c, boolean allowParagraphs) voidpart(StringBuilder b, XhtmlNode c, boolean trim, boolean allowParagraphs, boolean inPara)