Package org.opencms.ade.detailpage
Class CmsDetailPageInfo
- java.lang.Object
-
- org.opencms.ade.detailpage.CmsDetailPageInfo
-
- All Implemented Interfaces:
java.io.Serializable
public class CmsDetailPageInfo extends java.lang.Object implements java.io.Serializable
Data bean containing the information for a detail page.- Since:
- 8.0.0
- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description static java.lang.String
FUNCTION_PREFIX
The prefix for dynamic function detail page types.static java.lang.String
QUALIFIER_SEPARATOR
A string used to separate the type from the qualifier in the sitemap configuration.
-
Constructor Summary
Constructors Modifier Constructor Description protected
CmsDetailPageInfo()
Empty default constructor for serialization.CmsDetailPageInfo(CmsUUID id, java.lang.String uri, java.lang.String type, java.lang.String qualifier, java.lang.String iconClasses)
Creates a new detail page info bean.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description CmsDetailPageInfo
copyAsInherited()
Creates a copy of this entry, but sets the 'inherited' flag to true in the copy.boolean
equals(java.lang.Object obj)
java.lang.String
getDisplayType()
Gets the type name to display to the user.java.lang.String
getIconClasses()
Returns the resource icon style classes.java.lang.String
getIconType()
Returns the resource type name for the icon to display.CmsUUID
getId()
Returns the id of the detail page.java.lang.String
getQualifiedType()
Gets the type including the qualifier (if set).java.lang.String
getQualifier()
Gets the qualifier string.java.lang.String
getType()
Returns the type for which the detail page is used.java.lang.String
getUri()
The original URI for the detail page.int
hashCode()
boolean
isDefaultDetailPage()
Checks if this detail page has the default detail page type.boolean
isInherited()
Returns true if the detail page entry is inherited from a parent sitemap.static java.lang.String
removeFunctionPrefix(java.lang.String name)
Removes the prefix for dynamic functions from a detail page type name.java.lang.String
toString()
-
-
-
Field Detail
-
FUNCTION_PREFIX
public static final java.lang.String FUNCTION_PREFIX
The prefix for dynamic function detail page types.- See Also:
- Constant Field Values
-
QUALIFIER_SEPARATOR
public static final java.lang.String QUALIFIER_SEPARATOR
A string used to separate the type from the qualifier in the sitemap configuration.- See Also:
- Constant Field Values
-
-
Constructor Detail
-
CmsDetailPageInfo
public CmsDetailPageInfo(CmsUUID id, java.lang.String uri, java.lang.String type, java.lang.String qualifier, java.lang.String iconClasses)
Creates a new detail page info bean.- Parameters:
id
- the id of the detail pageuri
- the original URI of the pagetype
- the resource type for which the detail page is usedqualifier
- an optional string that indicates when the detail page should be usediconClasses
- the resource icon style classes
-
CmsDetailPageInfo
protected CmsDetailPageInfo()
Empty default constructor for serialization.
-
-
Method Detail
-
removeFunctionPrefix
public static java.lang.String removeFunctionPrefix(java.lang.String name)
Removes the prefix for dynamic functions from a detail page type name.- Parameters:
name
- the detail page type name- Returns:
- the detail page type name withotu the function prefix
-
copyAsInherited
public CmsDetailPageInfo copyAsInherited()
Creates a copy of this entry, but sets the 'inherited' flag to true in the copy.- Returns:
- the copy of this entry
-
equals
public boolean equals(java.lang.Object obj)
- Overrides:
equals
in classjava.lang.Object
- See Also:
Object.equals(java.lang.Object)
-
getDisplayType
public java.lang.String getDisplayType()
Gets the type name to display to the user.- Returns:
- the type name to display
-
getIconClasses
public java.lang.String getIconClasses()
Returns the resource icon style classes.- Returns:
- the resource icon style classes
-
getIconType
public java.lang.String getIconType()
Returns the resource type name for the icon to display.- Returns:
- the icon resource type
-
getQualifiedType
public java.lang.String getQualifiedType()
Gets the type including the qualifier (if set).This is the same format as used in the detail page type field in the sitemap configuration.
- Returns:
- the qualified type
-
getQualifier
public java.lang.String getQualifier()
Gets the qualifier string.The qualifier is an optional (i.e. possibly null) string that indicates when this detail page should be used.
- Returns:
- the qualifier string
-
getType
public java.lang.String getType()
Returns the type for which the detail page is used.- Returns:
- the type for which the detail page is used
-
getUri
public java.lang.String getUri()
The original URI for the detail page.- Returns:
- the original URI for the detail page
-
hashCode
public int hashCode()
- Overrides:
hashCode
in classjava.lang.Object
- See Also:
Object.hashCode()
-
isDefaultDetailPage
public boolean isDefaultDetailPage()
Checks if this detail page has the default detail page type.- Returns:
- true if this is a default detail page
-
isInherited
public boolean isInherited()
Returns true if the detail page entry is inherited from a parent sitemap.- Returns:
- true if the detail page entry is inherited from a parent sitemap
-
toString
public java.lang.String toString()
- Overrides:
toString
in classjava.lang.Object
- See Also:
Object.toString()
-
-