Package org.opencms.jsp.decorator
Class CmsDecorationObject
java.lang.Object
org.opencms.jsp.decorator.CmsDecorationObject
The CmsDecorationObject defines a single text decoration.
It uses the information of a
to create the
pre- and postfix for a text decoration.CmsDecorationDefintion
- Since:
- 6.1.3
-
Field Summary
-
Constructor Summary
ConstructorDescriptionConstructor, creates a new, empty decoration object.CmsDecorationObject
(String decorationKey, String decoration, CmsDecorationDefintion decDef, Locale locale) Constructor, creates a new decoration object with given values. -
Method Summary
Modifier and TypeMethodDescriptiongetContentDecoration
(I_CmsDecoratorConfiguration config, String text, String contentLocale) Gets the decorated content for this decoration object.Returns the decoration.Returns the decorationDefinition.Returns the decorationKey.toString()
-
Field Details
-
MACRO_DECORATION
Macro for the decoration.- See Also:
-
MACRO_DECORATIONKEY
Macro for the decoration key.- See Also:
-
MACRO_LANGUAGE
Macro for the language.- See Also:
-
MACRO_LOCALE
Macro for the locale.- See Also:
-
-
Constructor Details
-
CmsDecorationObject
public CmsDecorationObject()Constructor, creates a new, empty decoration object. -
CmsDecorationObject
public CmsDecorationObject(String decorationKey, String decoration, CmsDecorationDefintion decDef, Locale locale) Constructor, creates a new decoration object with given values.- Parameters:
decorationKey
- the decoration keydecoration
- the decoration for this decoration keydecDef
- the decoration defintion to be usedlocale
- the locale of this decoration object
-
-
Method Details
-
getContentDecoration
public String getContentDecoration(I_CmsDecoratorConfiguration config, String text, String contentLocale) Gets the decorated content for this decoration object.- Parameters:
config
- the configuration usedtext
- the text to be decoratedcontentLocale
- the locale of the content to be decorated- Returns:
- decorated content
-
getDecoration
Returns the decoration.- Returns:
- the decoration
-
getDecorationDefinition
Returns the decorationDefinition.- Returns:
- the decorationDefinition
-
getDecorationKey
Returns the decorationKey.- Returns:
- the decorationKey
-
toString
-