Class CmsFormatterBean
- java.lang.Object
-
- org.opencms.xml.containerpage.CmsFormatterBean
-
- All Implemented Interfaces:
java.lang.Cloneable
,I_CmsFormatterBean
- Direct Known Subclasses:
CmsFlexFormatterBean
,CmsFunctionFormatterBean
,CmsMacroFormatterBean
public class CmsFormatterBean extends java.lang.Object implements I_CmsFormatterBean, java.lang.Cloneable
A bean containing formatter configuration data as strings.- Since:
- 8.0.0
-
-
Field Summary
Fields Modifier and Type Field Description static int
DEFAULT_CONFIGURATION_RANK
Default rank for formatters from formatter configuration files.static int
DEFAULT_SCHEMA_RANK
Default rank for formatters defined in schema.protected java.util.Set<java.lang.String>
m_aliasKeys
Set of alias keys.protected java.util.Set<java.lang.String>
m_containerTypes
The formatter container type.protected java.util.Set<java.lang.String>
m_cssHeadIncludes
CSS Head includes.protected java.lang.String
m_description
The description text for the formatter.protected java.lang.String
m_displayType
Provides the display type.protected java.lang.String
m_id
The id for this formatter.protected java.lang.String
m_inlineCss
Inline CSS snippets.protected java.lang.String
m_inlineJavascript
Inline Javascript snippets.protected boolean
m_isAutoEnabled
Is the formatter automatically enabled?protected boolean
m_isDetail
True if this formatter can be used for detail views.protected boolean
m_isFromFormatterConfigFile
Is the formatter from a formatter configuration file?protected boolean
m_isPreviewFormatter
Indicates if this formatter is to be used as preview in the ADE gallery GUI.protected java.util.List<java.lang.String>
m_javascriptHeadIncludes
JavaScript head includes.protected java.lang.String
m_jspRootPath
The formatter JSP.protected CmsUUID
m_jspStructureId
The UUID of the JSP resource for this formatter.protected java.lang.String
m_key
The formatter key.protected java.lang.String
m_location
The location this formatter was configured in.protected boolean
m_matchAll
If true, will match any container/width combination.protected int
m_maxWidth
The formatter max width.protected java.util.List<CmsMetaMapping>
m_metaMappings
The meta mappings.protected int
m_minWidth
The formatter min width.protected boolean
m_nestedFormatterSettings
Indicates whether nested formatter settings should be displayed.protected java.lang.String
m_niceName
The nice name.protected java.util.List<CmsTemplatePlugin>
m_plugins
The referenced plugins.protected int
m_rank
The rank.protected java.util.Collection<java.lang.String>
m_resourceTypeNames
The resource type name.protected boolean
m_search
Indicates if the content should be searchable in the online index when this formatter is used.protected boolean
m_strictContainers
Indicating if this formatter will always render all nested containers.protected boolean
m_useMetaMappingsForNormalElements
Indicates whether meta mappings should be applied for all elements.static java.lang.String
PREVIEW_TYPE
Default formatter type constant.static int
PREVIEW_WIDTH
The width of the preview window for the formatters.static java.lang.String
WILDCARD_TYPE
Wildcard formatter type for width based formatters.
-
Constructor Summary
Constructors Constructor Description CmsFormatterBean(java.lang.String containerType, java.lang.String jspRootPath, java.lang.String minWidthStr, java.lang.String maxWidthStr, java.lang.String preview, java.lang.String searchContent, java.lang.String location)
Constructor for creating a new formatter configuration without resource structure id.CmsFormatterBean(java.lang.String containerType, java.lang.String rootPath, CmsUUID structureId, int minWidth, int maxWidth, boolean preview, boolean searchContent, java.lang.String location)
Constructor for creating a new formatter configuration with resource structure id.CmsFormatterBean(java.util.Set<java.lang.String> containerTypes, java.lang.String jspRootPath, CmsUUID jspStructureId, java.lang.String key, java.util.Set<java.lang.String> aliasKeys, int minWidth, int maxWidth, boolean preview, boolean searchContent, java.lang.String location, java.util.List<java.lang.String> cssHeadIncludes, java.lang.String inlineCss, java.util.List<java.lang.String> javascriptHeadIncludes, java.lang.String inlineJavascript, java.util.List<CmsTemplatePlugin> plugins, java.lang.String niceName, java.lang.String description, java.util.Collection<java.lang.String> resourceTypeNames, int rank, java.lang.String id, CmsSettingConfiguration settingConfig, boolean isFromConfigFile, boolean isAutoEnabled, boolean isDetail, java.lang.String displayType, boolean isAllowsSettingsInEditor, boolean strictContainers, boolean nestedFormatterSettings, java.util.List<CmsMetaMapping> metaMappings, java.util.Map<java.lang.String,java.lang.String> attributes, boolean useMetaMappingsForNormalElements)
Constructor for creating a new formatter configuration with resource structure id.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description java.util.Set<java.lang.String>
getAliasKeys()
Gets the set of alias keys for the formatter.java.util.Set<java.lang.String>
getAllKeys()
Gets the complete set of keys for the formatter, i.e.java.util.Map<java.lang.String,java.lang.String>
getAttributes()
Gets the map of attributes.java.util.Set<java.lang.String>
getContainerTypes()
Returns the formatter container type.java.util.Set<java.lang.String>
getCssHeadIncludes()
Gets the CSS head includes.java.lang.String
getDescription(java.util.Locale locale)
Gets the formatter description.java.lang.String
getDisplayType()
The display type of this formatter ornull
in case this is not a display formatter.java.lang.String
getId()
Returns the id of this formatter.java.lang.String
getInlineCss()
Gets the inline CSS snippets.java.lang.String
getInlineJavascript()
Gets the inline JS snippets.java.util.List<java.lang.String>
getJavascriptHeadIncludes()
Gets the Javascript head includes.java.lang.String
getJspRootPath()
Returns the root path of the formatter JSP in the OpenCms VFS.CmsUUID
getJspStructureId()
Returns the structure id of the JSP resource for this formatter.java.lang.String
getKey()
Gets the formatter key, or null if no formatter key is set.java.lang.String
getLocation()
Returns the location this formatter was defined in.int
getMaxWidth()
Returns the maximum formatter width.java.util.List<CmsMetaMapping>
getMetaMappings()
Returns the meta mappings.int
getMinWidth()
Returns the minimum formatter width.java.lang.String
getNiceName(java.util.Locale locale)
Gets the nice name for this formatter.int
getRank()
Gets the rank.java.util.Collection<java.lang.String>
getResourceTypeNames()
Gets the resource type names.java.util.Map<java.lang.String,CmsXmlContentProperty>
getSettings(CmsADEConfigData config)
Gets the defined settings.java.util.List<CmsTemplatePlugin>
getTemplatePlugins()
Gets the template plugins.int
hashCode()
boolean
hasNestedFormatterSettings()
Returns if nested formatter settings should be displayed.boolean
isAllowsSettingsInEditor()
Returns whether this formatter allows settings to be edited in the content editor.boolean
isAutoEnabled()
Returns true if the formatter is automatically enabled.boolean
isDetailFormatter()
Returns true if the formatter can be used for detail views.boolean
isDisplayFormatter()
Returns whether this formatter should be used by the 'display' tag.boolean
isFromFormatterConfigFile()
Returns true if the formatter is from a formatter configuration file.boolean
isMatchAll()
Returns true if this formatter should match all type/width combinations.boolean
isPreviewFormatter()
Indicates if this formatter is to be used as preview in the ADE gallery GUI.static boolean
isPreviewType(java.lang.String containerType)
Checks if the given container type matches the ADE gallery preview type.boolean
isSearchContent()
Returnstrue
in case an XML content formatted with this formatter should be included in the online full text search.boolean
isStrictContainers()
Returns whether this formatter will always render all nested containers.boolean
isTypeFormatter()
Returnstrue
in case this formatter is based on type information.void
setJspStructureId(CmsUUID jspStructureId)
Sets the structure id of the JSP for this formatter.java.lang.String
toString()
boolean
useMetaMappingsForNormalElements()
Returns true if meta mappings should be evaluated for normal container elements using this formatter, not just detail elements.java.util.Optional<I_CmsFormatterBean>
withKeys(java.util.Collection<java.lang.String> keys)
If possible, returns a formatter bean that is basically a copy of this one, but has the keys supplied as a parameter.-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface org.opencms.xml.containerpage.I_CmsFormatterBean
getKeyOrId
-
-
-
-
Field Detail
-
DEFAULT_CONFIGURATION_RANK
public static final int DEFAULT_CONFIGURATION_RANK
Default rank for formatters from formatter configuration files.- See Also:
- Constant Field Values
-
DEFAULT_SCHEMA_RANK
public static final int DEFAULT_SCHEMA_RANK
Default rank for formatters defined in schema.- See Also:
- Constant Field Values
-
PREVIEW_TYPE
public static final java.lang.String PREVIEW_TYPE
Default formatter type constant.- See Also:
- Constant Field Values
-
PREVIEW_WIDTH
public static final int PREVIEW_WIDTH
The width of the preview window for the formatters.- See Also:
- Constant Field Values
-
WILDCARD_TYPE
public static final java.lang.String WILDCARD_TYPE
Wildcard formatter type for width based formatters.- See Also:
- Constant Field Values
-
m_containerTypes
protected java.util.Set<java.lang.String> m_containerTypes
The formatter container type.
-
m_cssHeadIncludes
protected java.util.Set<java.lang.String> m_cssHeadIncludes
CSS Head includes.
-
m_description
protected java.lang.String m_description
The description text for the formatter.
-
m_aliasKeys
protected java.util.Set<java.lang.String> m_aliasKeys
Set of alias keys.
-
m_displayType
protected java.lang.String m_displayType
Provides the display type. If empty if this formatter should not be used by the display tag.
-
m_id
protected java.lang.String m_id
The id for this formatter.
-
m_inlineCss
protected java.lang.String m_inlineCss
Inline CSS snippets.
-
m_inlineJavascript
protected java.lang.String m_inlineJavascript
Inline Javascript snippets.
-
m_isAutoEnabled
protected boolean m_isAutoEnabled
Is the formatter automatically enabled?
-
m_isDetail
protected boolean m_isDetail
True if this formatter can be used for detail views.
-
m_isFromFormatterConfigFile
protected boolean m_isFromFormatterConfigFile
Is the formatter from a formatter configuration file?
-
m_isPreviewFormatter
protected boolean m_isPreviewFormatter
Indicates if this formatter is to be used as preview in the ADE gallery GUI.
-
m_javascriptHeadIncludes
protected java.util.List<java.lang.String> m_javascriptHeadIncludes
JavaScript head includes.
-
m_jspRootPath
protected java.lang.String m_jspRootPath
The formatter JSP.
-
m_jspStructureId
protected CmsUUID m_jspStructureId
The UUID of the JSP resource for this formatter.
-
m_key
protected java.lang.String m_key
The formatter key.
-
m_location
protected java.lang.String m_location
The location this formatter was configured in.
-
m_matchAll
protected boolean m_matchAll
If true, will match any container/width combination.
-
m_maxWidth
protected int m_maxWidth
The formatter max width.
-
m_metaMappings
protected java.util.List<CmsMetaMapping> m_metaMappings
The meta mappings.
-
m_minWidth
protected int m_minWidth
The formatter min width.
-
m_nestedFormatterSettings
protected boolean m_nestedFormatterSettings
Indicates whether nested formatter settings should be displayed.
-
m_niceName
protected java.lang.String m_niceName
The nice name.
-
m_plugins
protected java.util.List<CmsTemplatePlugin> m_plugins
The referenced plugins.
-
m_rank
protected int m_rank
The rank.
-
m_resourceTypeNames
protected java.util.Collection<java.lang.String> m_resourceTypeNames
The resource type name.
-
m_search
protected boolean m_search
Indicates if the content should be searchable in the online index when this formatter is used.
-
m_strictContainers
protected boolean m_strictContainers
Indicating if this formatter will always render all nested containers.
-
m_useMetaMappingsForNormalElements
protected boolean m_useMetaMappingsForNormalElements
Indicates whether meta mappings should be applied for all elements.
-
-
Constructor Detail
-
CmsFormatterBean
public CmsFormatterBean(java.util.Set<java.lang.String> containerTypes, java.lang.String jspRootPath, CmsUUID jspStructureId, java.lang.String key, java.util.Set<java.lang.String> aliasKeys, int minWidth, int maxWidth, boolean preview, boolean searchContent, java.lang.String location, java.util.List<java.lang.String> cssHeadIncludes, java.lang.String inlineCss, java.util.List<java.lang.String> javascriptHeadIncludes, java.lang.String inlineJavascript, java.util.List<CmsTemplatePlugin> plugins, java.lang.String niceName, java.lang.String description, java.util.Collection<java.lang.String> resourceTypeNames, int rank, java.lang.String id, CmsSettingConfiguration settingConfig, boolean isFromConfigFile, boolean isAutoEnabled, boolean isDetail, java.lang.String displayType, boolean isAllowsSettingsInEditor, boolean strictContainers, boolean nestedFormatterSettings, java.util.List<CmsMetaMapping> metaMappings, java.util.Map<java.lang.String,java.lang.String> attributes, boolean useMetaMappingsForNormalElements)
Constructor for creating a new formatter configuration with resource structure id.- Parameters:
containerTypes
- the formatter container typesjspRootPath
- the formatter JSP VFS root pathjspStructureId
- the structure id of the formatter JSPkey
- the formatter keyaliasKeys
- the alias keysminWidth
- the formatter min widthmaxWidth
- the formatter max widthpreview
- indicates if this formatter is to be used for the preview in the ADE gallery GUIsearchContent
- indicates if the content should be searchable in the online index when this formatter is usedlocation
- the location where this formatter was defined, should be an OpenCms VFS resource pathcssHeadIncludes
- the CSS head includesinlineCss
- the in-line CSSjavascriptHeadIncludes
- the JavaScript headincludesinlineJavascript
- the in-line JavaScriptplugins
- the template pluginsniceName
- the configuration display namedescription
- the description text for the formatterresourceTypeNames
- the resource type namesrank
- the configuration rankid
- the configuration idsettingConfig
- the settings configurationisFromConfigFile
-true
if configuration file basedisAutoEnabled
-true
if auto enabledisDetail
-true
if detail formatterdisplayType
- the display typeisAllowsSettingsInEditor
- whether this formatter allows settings to be edited in the content editorstrictContainers
-true
if this formatter will always render all nested containersnestedFormatterSettings
- indicates whether nested formatter settings should be displayedmetaMappings
- the meta mappingsattributes
- the formatter attributesuseMetaMappingsForNormalElements
- if true, meta mappings will be evaluated for normal container elements, not just detail elements
-
CmsFormatterBean
public CmsFormatterBean(java.lang.String containerType, java.lang.String rootPath, CmsUUID structureId, int minWidth, int maxWidth, boolean preview, boolean searchContent, java.lang.String location)
Constructor for creating a new formatter configuration with resource structure id.- Parameters:
containerType
- the formatter container typesrootPath
- the formatter JSP VFS root pathstructureId
- the structure id of the formatter JSPminWidth
- the formatter min widthmaxWidth
- the formatter max widthpreview
- indicates if this formatter is to be used for the preview in the ADE gallery GUIsearchContent
- indicates if the content should be searchable in the online index when this formatter is usedlocation
- the location where this formatter was defined, should be an OpenCms VFS resource path
-
CmsFormatterBean
public CmsFormatterBean(java.lang.String containerType, java.lang.String jspRootPath, java.lang.String minWidthStr, java.lang.String maxWidthStr, java.lang.String preview, java.lang.String searchContent, java.lang.String location)
Constructor for creating a new formatter configuration without resource structure id.- Parameters:
containerType
- the formatter container typejspRootPath
- the formatter JSP VFS root pathminWidthStr
- the formatter min widthmaxWidthStr
- the formatter max widthpreview
- indicates if this formatter is to be used for the preview in the ADE gallery GUIsearchContent
- indicates if the content should be searchable in the online index when this formatter is usedlocation
- the location where this formatter was defined, should be an OpenCms VFS resource path
-
-
Method Detail
-
isPreviewType
public static boolean isPreviewType(java.lang.String containerType)
Checks if the given container type matches the ADE gallery preview type.- Parameters:
containerType
- the container type to check- Returns:
true
if the given container type matches the ADE gallery preview type
-
getAliasKeys
public java.util.Set<java.lang.String> getAliasKeys()
Description copied from interface:I_CmsFormatterBean
Gets the set of alias keys for the formatter.- Specified by:
getAliasKeys
in interfaceI_CmsFormatterBean
- Returns:
- the set of alias keys
- See Also:
I_CmsFormatterBean.getAliasKeys()
-
getAllKeys
public java.util.Set<java.lang.String> getAllKeys()
Description copied from interface:I_CmsFormatterBean
Gets the complete set of keys for the formatter, i.e. its main key and all alias keys.- Specified by:
getAllKeys
in interfaceI_CmsFormatterBean
- Returns:
- the complete set of keys
- See Also:
I_CmsFormatterBean.getAllKeys()
-
getAttributes
public java.util.Map<java.lang.String,java.lang.String> getAttributes()
Description copied from interface:I_CmsFormatterBean
Gets the map of attributes.- Specified by:
getAttributes
in interfaceI_CmsFormatterBean
- Returns:
- the attribute map
- See Also:
I_CmsFormatterBean.getAttributes()
-
getContainerTypes
public java.util.Set<java.lang.String> getContainerTypes()
Description copied from interface:I_CmsFormatterBean
Returns the formatter container type.If this is "*", then the formatter is a width based formatter.
- Specified by:
getContainerTypes
in interfaceI_CmsFormatterBean
- Returns:
- the formatter container type
- See Also:
I_CmsFormatterBean.getContainerTypes()
-
getCssHeadIncludes
public java.util.Set<java.lang.String> getCssHeadIncludes()
Description copied from interface:I_CmsFormatterBean
Gets the CSS head includes.- Specified by:
getCssHeadIncludes
in interfaceI_CmsFormatterBean
- Returns:
- the CSS head includes
- See Also:
I_CmsFormatterBean.getCssHeadIncludes()
-
getDescription
public java.lang.String getDescription(java.util.Locale locale)
Description copied from interface:I_CmsFormatterBean
Gets the formatter description.If a locale is passed in, macros in the configured description will be resolved with a macro resolver set to that locale. If null is passed in as a locale, the raw configured description will be returned.
- Specified by:
getDescription
in interfaceI_CmsFormatterBean
- Parameters:
locale
- the locale (may be null)- Returns:
- the formatter description
- See Also:
I_CmsFormatterBean.getDescription(Locale)
-
getDisplayType
public java.lang.String getDisplayType()
Description copied from interface:I_CmsFormatterBean
The display type of this formatter ornull
in case this is not a display formatter.- Specified by:
getDisplayType
in interfaceI_CmsFormatterBean
- Returns:
- the display type
- See Also:
I_CmsFormatterBean.getDisplayType()
-
getId
public java.lang.String getId()
Description copied from interface:I_CmsFormatterBean
Returns the id of this formatter.This method may return null because the id is not always defined for formatters, e.g. for those formatters declared in a schema.
- Specified by:
getId
in interfaceI_CmsFormatterBean
- Returns:
- the formatter id
- See Also:
I_CmsFormatterBean.getId()
-
getInlineCss
public java.lang.String getInlineCss()
Description copied from interface:I_CmsFormatterBean
Gets the inline CSS snippets.- Specified by:
getInlineCss
in interfaceI_CmsFormatterBean
- Returns:
- the inline CSS snippets
- See Also:
I_CmsFormatterBean.getInlineCss()
-
getInlineJavascript
public java.lang.String getInlineJavascript()
Description copied from interface:I_CmsFormatterBean
Gets the inline JS snippets.- Specified by:
getInlineJavascript
in interfaceI_CmsFormatterBean
- Returns:
- the inline JS snippets
- See Also:
I_CmsFormatterBean.getInlineJavascript()
-
getJavascriptHeadIncludes
public java.util.List<java.lang.String> getJavascriptHeadIncludes()
Description copied from interface:I_CmsFormatterBean
Gets the Javascript head includes.- Specified by:
getJavascriptHeadIncludes
in interfaceI_CmsFormatterBean
- Returns:
- the head includes
- See Also:
I_CmsFormatterBean.getJavascriptHeadIncludes()
-
getJspRootPath
public java.lang.String getJspRootPath()
Description copied from interface:I_CmsFormatterBean
Returns the root path of the formatter JSP in the OpenCms VFS.- Specified by:
getJspRootPath
in interfaceI_CmsFormatterBean
- Returns:
- the root path of the formatter JSP in the OpenCms VFS.
- See Also:
I_CmsFormatterBean.getJspRootPath()
-
getJspStructureId
public CmsUUID getJspStructureId()
Description copied from interface:I_CmsFormatterBean
Returns the structure id of the JSP resource for this formatter.- Specified by:
getJspStructureId
in interfaceI_CmsFormatterBean
- Returns:
- the structure id of the JSP resource for this formatter
- See Also:
I_CmsFormatterBean.getJspStructureId()
-
getKey
public java.lang.String getKey()
Description copied from interface:I_CmsFormatterBean
Gets the formatter key, or null if no formatter key is set.A formatter key is used to allow dynamic switching between formatters with the same key by enabling/disabling the formatters in the sitemap configuration. I.e. if a formatter referenced in a container page has been disabled in the sitemap configuration, but a different formatter with the same key is enabled, the second formatter will be used instead when rendering the page .
- Specified by:
getKey
in interfaceI_CmsFormatterBean
- Returns:
- the formatter key, or null
- See Also:
I_CmsFormatterBean.getKey()
-
getLocation
public java.lang.String getLocation()
Description copied from interface:I_CmsFormatterBean
Returns the location this formatter was defined in.This will be an OpenCms VFS root path, either to the XML schema XSD, or the configuration file this formatter was defined in, or to the JSP that makes up this formatter.
- Specified by:
getLocation
in interfaceI_CmsFormatterBean
- Returns:
- the location this formatter was defined in
- See Also:
I_CmsFormatterBean.getLocation()
-
getMaxWidth
public int getMaxWidth()
Description copied from interface:I_CmsFormatterBean
Returns the maximum formatter width.If this is not set, then
Integer.MAX_VALUE
is returned.- Specified by:
getMaxWidth
in interfaceI_CmsFormatterBean
- Returns:
- the maximum formatter width
- See Also:
I_CmsFormatterBean.getMaxWidth()
-
getMetaMappings
public java.util.List<CmsMetaMapping> getMetaMappings()
Description copied from interface:I_CmsFormatterBean
Returns the meta mappings.- Specified by:
getMetaMappings
in interfaceI_CmsFormatterBean
- Returns:
- the meta mappings
- See Also:
I_CmsFormatterBean.getMetaMappings()
-
getMinWidth
public int getMinWidth()
Description copied from interface:I_CmsFormatterBean
Returns the minimum formatter width.If this is not set, then
-1
is returned.- Specified by:
getMinWidth
in interfaceI_CmsFormatterBean
- Returns:
- the minimum formatter width
- See Also:
I_CmsFormatterBean.getMinWidth()
-
getNiceName
public java.lang.String getNiceName(java.util.Locale locale)
Description copied from interface:I_CmsFormatterBean
Gets the nice name for this formatter.- Specified by:
getNiceName
in interfaceI_CmsFormatterBean
- Parameters:
locale
- the locale- Returns:
- the nice name for this formatter
- See Also:
I_CmsFormatterBean.getNiceName(Locale)
-
getRank
public int getRank()
Description copied from interface:I_CmsFormatterBean
Gets the rank.- Specified by:
getRank
in interfaceI_CmsFormatterBean
- Returns:
- the rank
- See Also:
I_CmsFormatterBean.getRank()
-
getResourceTypeNames
public java.util.Collection<java.lang.String> getResourceTypeNames()
Description copied from interface:I_CmsFormatterBean
Gets the resource type names.- Specified by:
getResourceTypeNames
in interfaceI_CmsFormatterBean
- Returns:
- the resource type names
- See Also:
I_CmsFormatterBean.getResourceTypeNames()
-
getSettings
public java.util.Map<java.lang.String,CmsXmlContentProperty> getSettings(CmsADEConfigData config)
Description copied from interface:I_CmsFormatterBean
Gets the defined settings.- Specified by:
getSettings
in interfaceI_CmsFormatterBean
- Parameters:
config
- the sitemap configuration for which the settings should be retrieved- Returns:
- the defined settings
- See Also:
I_CmsFormatterBean.getSettings(org.opencms.ade.configuration.CmsADEConfigData)
-
getTemplatePlugins
public java.util.List<CmsTemplatePlugin> getTemplatePlugins()
Description copied from interface:I_CmsFormatterBean
Gets the template plugins.- Specified by:
getTemplatePlugins
in interfaceI_CmsFormatterBean
- Returns:
- the template plugins
- See Also:
I_CmsFormatterBean.getTemplatePlugins()
-
hashCode
public int hashCode()
- Overrides:
hashCode
in classjava.lang.Object
- See Also:
Object.hashCode()
-
hasNestedFormatterSettings
public boolean hasNestedFormatterSettings()
Description copied from interface:I_CmsFormatterBean
Returns if nested formatter settings should be displayed.- Specified by:
hasNestedFormatterSettings
in interfaceI_CmsFormatterBean
- Returns:
true
if nested formatter settings should be displayed- See Also:
I_CmsFormatterBean.hasNestedFormatterSettings()
-
isAllowsSettingsInEditor
public boolean isAllowsSettingsInEditor()
Description copied from interface:I_CmsFormatterBean
Returns whether this formatter allows settings to be edited in the content editor.- Specified by:
isAllowsSettingsInEditor
in interfaceI_CmsFormatterBean
- Returns:
true
in case editing the settings is allowed in the content editor- See Also:
I_CmsFormatterBean.isAllowsSettingsInEditor()
-
isAutoEnabled
public boolean isAutoEnabled()
Description copied from interface:I_CmsFormatterBean
Returns true if the formatter is automatically enabled.- Specified by:
isAutoEnabled
in interfaceI_CmsFormatterBean
- Returns:
- true if the formatter is automatically enabled
- See Also:
I_CmsFormatterBean.isAutoEnabled()
-
isDetailFormatter
public boolean isDetailFormatter()
Description copied from interface:I_CmsFormatterBean
Returns true if the formatter can be used for detail views.- Specified by:
isDetailFormatter
in interfaceI_CmsFormatterBean
- Returns:
- true if the formatter can be used for detail views
- See Also:
I_CmsFormatterBean.isDetailFormatter()
-
isDisplayFormatter
public boolean isDisplayFormatter()
Description copied from interface:I_CmsFormatterBean
Returns whether this formatter should be used by the 'display' tag.- Specified by:
isDisplayFormatter
in interfaceI_CmsFormatterBean
- Returns:
true
if this formatter should be used by the 'display' tag- See Also:
I_CmsFormatterBean.isDisplayFormatter()
-
isFromFormatterConfigFile
public boolean isFromFormatterConfigFile()
Description copied from interface:I_CmsFormatterBean
Returns true if the formatter is from a formatter configuration file.- Specified by:
isFromFormatterConfigFile
in interfaceI_CmsFormatterBean
- Returns:
- formatter f
- See Also:
I_CmsFormatterBean.isFromFormatterConfigFile()
-
isMatchAll
public boolean isMatchAll()
Description copied from interface:I_CmsFormatterBean
Returns true if this formatter should match all type/width combinations.- Specified by:
isMatchAll
in interfaceI_CmsFormatterBean
- Returns:
- true if this formatter should match all type/width combinations
- See Also:
I_CmsFormatterBean.isMatchAll()
-
isPreviewFormatter
public boolean isPreviewFormatter()
Description copied from interface:I_CmsFormatterBean
Indicates if this formatter is to be used as preview in the ADE gallery GUI.- Specified by:
isPreviewFormatter
in interfaceI_CmsFormatterBean
- Returns:
true
if this formatter is to be used as preview in the ADE gallery GUI- See Also:
I_CmsFormatterBean.isPreviewFormatter()
-
isSearchContent
public boolean isSearchContent()
Description copied from interface:I_CmsFormatterBean
Returnstrue
in case an XML content formatted with this formatter should be included in the online full text search.- Specified by:
isSearchContent
in interfaceI_CmsFormatterBean
- Returns:
true
in case an XML content formatted with this formatter should be included in the online full text search- See Also:
I_CmsFormatterBean.isSearchContent()
-
isStrictContainers
public boolean isStrictContainers()
Returns whether this formatter will always render all nested containers.- Returns:
true
if this formatter will always render all nested containers
-
isTypeFormatter
public boolean isTypeFormatter()
Description copied from interface:I_CmsFormatterBean
Returnstrue
in case this formatter is based on type information.- Specified by:
isTypeFormatter
in interfaceI_CmsFormatterBean
- Returns:
true
in case this formatter is based on type information- See Also:
I_CmsFormatterBean.isTypeFormatter()
-
setJspStructureId
public void setJspStructureId(CmsUUID jspStructureId)
Sets the structure id of the JSP for this formatter.This is "package visible" as it should be only called from
CmsFormatterConfiguration.initialize(org.opencms.file.CmsObject)
.- Specified by:
setJspStructureId
in interfaceI_CmsFormatterBean
- Parameters:
jspStructureId
- the structure id of the JSP for this formatter
-
toString
public java.lang.String toString()
- Overrides:
toString
in classjava.lang.Object
- See Also:
Object.toString()
-
useMetaMappingsForNormalElements
public boolean useMetaMappingsForNormalElements()
Description copied from interface:I_CmsFormatterBean
Returns true if meta mappings should be evaluated for normal container elements using this formatter, not just detail elements.- Specified by:
useMetaMappingsForNormalElements
in interfaceI_CmsFormatterBean
- Returns:
- true if meta mappings should be evaluated for normal container elements
- See Also:
I_CmsFormatterBean.useMetaMappingsForNormalElements()
-
withKeys
public java.util.Optional<I_CmsFormatterBean> withKeys(java.util.Collection<java.lang.String> keys)
Description copied from interface:I_CmsFormatterBean
If possible, returns a formatter bean that is basically a copy of this one, but has the keys supplied as a parameter.Note that this only works for formatters which already have a key, and can not replace the main key. If the keys already match, the current instance may be returned rather than a copy.
If the formatter bean implementation does not support key replacement, or an error occurs, an empty Optional is returned
- Specified by:
withKeys
in interfaceI_CmsFormatterBean
- Parameters:
keys
- the keys to use (should include the current key of the formatter- Returns:
- the copy with the replaced keys
- See Also:
I_CmsFormatterBean.withKeys(java.util.Collection)
-
-