Package org.ametys.cms.data
Class RichTextHelper
java.lang.Object
org.ametys.runtime.plugin.component.AbstractLogEnabled
org.ametys.cms.data.RichTextHelper
- All Implemented Interfaces:
LogEnabled,Component,Serviceable
Rich-text helper
-
Field Summary
FieldsModifier and TypeFieldDescriptionprotected ServiceManagerThe service managerstatic final StringThe Avalon role -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionrichTextToString(RichText richText) Transform the rich text to stringrichTextToString(RichText richText, int maxSize) Transform the rich text to stringvoidservice(ServiceManager manager) Methods inherited from class org.ametys.runtime.plugin.component.AbstractLogEnabled
getLogger, setLogger
-
Field Details
-
ROLE
The Avalon role -
_manager
The service manager
-
-
Constructor Details
-
RichTextHelper
public RichTextHelper()
-
-
Method Details
-
service
- Specified by:
servicein interfaceServiceable- Throws:
ServiceException
-
richTextToString
Transform the rich text to string- Parameters:
richText- the rich-text to transform- Returns:
- the transformed rich-text
-
richTextToString
Transform the rich text to string- Parameters:
richText- the rich-text to transformmaxSize- the max size of the rich-text. 0 if no max size- Returns:
- the transformed rich-text
-