public class EditorBbcodeService extends Object implements IEditorBbcodeService
| Constructor and Description |
|---|
EditorBbcodeService() |
| Modifier and Type | Method and Description |
|---|---|
static EditorBbcodeService |
getInstance()
Returns the unique instance of the service
|
void |
init()
Init service
|
String |
parse(String strValue)
Parse BBCODE text and return safe HTML
This method clean a
body fragment of HTML with Safelist.basicWithImages() |
String |
parseAndClean(String strValue,
org.jsoup.safety.Safelist safelist)
Parses the input string using BBCodeUtil.parse() and cleans the resulting HTML
using Jsoup.clean() with the specified Safelist, and returns the cleaned string.
|
public String parse(String strValue)
body fragment of HTML with Safelist.basicWithImages()parse in interface IEditorBbcodeServicestrValue - the value of the textpublic String parseAndClean(String strValue, org.jsoup.safety.Safelist safelist)
parseAndClean in interface IEditorBbcodeServicestrValue - the input string to be parsed and cleanedsafelist - the Safelist to be used for cleaning the HTMLpublic static EditorBbcodeService getInstance()
public void init()
Copyright © 2023 City of Paris. All rights reserved.