# Class HtmlSerializer

java.lang.Object
com.codename1.ui.editor.HtmlSerializer

public final class HtmlSerializer extends Object
Serializes the pure rich text editor model (text + `InlineStyles` + `RichBlocks`) back into an HTML string for `RichTextArea#getHtml`. The output is model canonical rather than byte identical, which matches how a `contenteditable` surface normalized HTML in the previous backend.

- ## Method Summary

  Modifier and Type
  Method
  Description
  `static String`
  `serialize(EditorDocument doc, InlineStyles inline, RichBlocks blocks, List<String> links, List<String> imageSources)`
  Serializes the model into HTML.

  ### Methods inherited from class Object

  `clone, equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- ## Method Details

  - ### serialize

    public static String serialize(EditorDocument doc, InlineStyles inline, RichBlocks blocks, List<String> links, List<String> imageSources)

    Serializes the model into HTML.

    ###### Parameters

    - `doc`: the text document

    - `inline`: the inline style model

    - `blocks`: the block attribute model