Class MDFXUtil

java.lang.Object
one.jpro.platform.mdfx.MDFXUtil

public class MDFXUtil extends Object
Utility class for splitting Markdown text into Chapters and Subchapters.
  • Constructor Details

    • MDFXUtil

      public MDFXUtil()
  • Method Details

    • getChapters

      public static List<MDFXUtil.Chapter> getChapters(String markdown)
      Parses the given Markdown string and splits it into a list of Chapter objects. Level 1 headings (#) are treated as Chapters. Level 2 headings (##) are treated as Subchapters.
      Parameters:
      markdown - the input Markdown string
      Returns:
      a list of Chapter objects, each containing zero or more Subchapters