Class StaticRichTextConfiguration.StaticRichTextConfigurationAttribute
java.lang.Object
org.ametys.core.ui.widgets.richtext.StaticRichTextConfiguration.StaticRichTextConfigurationAttribute
- All Implemented Interfaces:
RichTextConfigurationAttribute
- Enclosing class:
- StaticRichTextConfiguration
public static class StaticRichTextConfiguration.StaticRichTextConfigurationAttribute
extends Object
implements RichTextConfigurationAttribute
A configured implementation of the
StaticRichTextConfiguration.StaticRichTextConfigurationAttribute
-
Field Summary
-
Constructor Summary
ModifierConstructorDescriptionStaticRichTextConfigurationAttribute
(String name, String defaultValue, Set<String> authorizedValues, Set<String> technicalValues) Create by valuesprotected
StaticRichTextConfigurationAttribute
(Configuration configuration) Create by configuration -
Method Summary
Modifier and TypeMethodDescriptionGet the values that can be used on this attribute.Get the default value for this attribute.getName()
Get the attribute nameOnly applyable to the "class" attribute.
Between the authorized values, some are "technical" values (by opposition to "style" values).
-
Field Details
-
_name
The name of the attribute -
_defaultValue
The default value -
_authorizedValues
The possible values -
_technicalValues
The technical values
-
-
Constructor Details
-
StaticRichTextConfigurationAttribute
public StaticRichTextConfigurationAttribute(String name, String defaultValue, Set<String> authorizedValues, Set<String> technicalValues) Create by values- Parameters:
name
- The attribute name. Cannot be null.defaultValue
- The default value. Can be nullauthorizedValues
- A non-null set of authorized values. Must contains the default value.technicalValues
- A non-null set of technical values. Must contains the default value.
-
StaticRichTextConfigurationAttribute
protected StaticRichTextConfigurationAttribute(Configuration configuration) throws ConfigurationException Create by configuration- Parameters:
configuration
- The tag configuration- Throws:
ConfigurationException
- If an error occurred
-
-
Method Details
-
getName
Description copied from interface:RichTextConfigurationAttribute
Get the attribute name- Specified by:
getName
in interfaceRichTextConfigurationAttribute
- Returns:
- a non null and non empty value
-
getDefaultValue
Description copied from interface:RichTextConfigurationAttribute
Get the default value for this attribute. An attribute with a default value will always be present in the code.- Specified by:
getDefaultValue
in interfaceRichTextConfigurationAttribute
- Returns:
- Can be null if there is no default value.
-
getAuthorizedValues
Description copied from interface:RichTextConfigurationAttribute
Get the values that can be used on this attribute.- Specified by:
getAuthorizedValues
in interfaceRichTextConfigurationAttribute
- Returns:
- A non null set of possible values.
-
getTechnicalValues
Description copied from interface:RichTextConfigurationAttribute
Only applyable to the "class" attribute.
Between the authorized values, some are "technical" values (by opposition to "style" values). Theses values should not be removed if the style of the tag change.
For example when going from a "bordered" image to a "large bordered" image... the image should stay "float to the right".- Specified by:
getTechnicalValues
in interfaceRichTextConfigurationAttribute
- Returns:
- A non null set of values.
-