Package org.opencms.jsp.decorator
Class CmsDecorationMap
- java.lang.Object
-
- org.opencms.jsp.decorator.CmsDecorationMap
-
- All Implemented Interfaces:
java.lang.Comparable<CmsDecorationMap>
public class CmsDecorationMap extends java.lang.Object implements java.lang.Comparable<CmsDecorationMap>
The CmsDecorationMap is the object representation of a single decoartion file.The semicolon seperated elements of the decoartion file are stored in a map.
The map uses the decoration as keys and CmsDecorationObjects as values.
Multiple CmsDecorationMaps form a CmsDecorationBundle.
- Since:
- 6.1.3
-
-
Field Summary
Fields Modifier and Type Field Description static java.lang.String
CSV_SEPERATOR
The seperator for the CSV file.
-
Constructor Summary
Constructors Constructor Description CmsDecorationMap(CmsObject cms, CmsResource res, CmsDecorationDefintion decDef)
Constructor, creates a new CmsDecorationMap.CmsDecorationMap(CmsDecorationDefintion decDef, java.lang.String name, java.util.Locale locale)
Constructor, creates a new, empty CmsDecorationMap.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description int
compareTo(CmsDecorationMap o)
boolean
equals(java.lang.Object obj)
java.util.Map<java.lang.String,CmsDecorationObject>
getDecorationMap()
Returns the decorationMap.java.util.Locale
getLocale()
Returns the locale.java.lang.String
getName()
Returns the name.int
hashCode()
void
setDecorationMap(java.util.Map<java.lang.String,CmsDecorationObject> decorationMap)
Sets the decorationMap.java.lang.String
toString()
-
-
-
Field Detail
-
CSV_SEPERATOR
public static final java.lang.String CSV_SEPERATOR
The seperator for the CSV file.- See Also:
- Constant Field Values
-
-
Constructor Detail
-
CmsDecorationMap
public CmsDecorationMap(CmsDecorationDefintion decDef, java.lang.String name, java.util.Locale locale)
Constructor, creates a new, empty CmsDecorationMap.- Parameters:
decDef
- the CmsDecorationDefintion to be used in this decoration mapname
- The name of the decoration maplocale
- the locale for this decoration map
-
CmsDecorationMap
public CmsDecorationMap(CmsObject cms, CmsResource res, CmsDecorationDefintion decDef) throws CmsException
Constructor, creates a new CmsDecorationMap.- Parameters:
cms
- the CmsObjectres
- the resource to extrace the decorations fromdecDef
- the CmsDecorationDefintion to be used in this decoration map- Throws:
CmsException
- if something goes wrong
-
-
Method Detail
-
compareTo
public int compareTo(CmsDecorationMap o)
- Specified by:
compareTo
in interfacejava.lang.Comparable<CmsDecorationMap>
- See Also:
Comparable.compareTo(java.lang.Object)
-
equals
public boolean equals(java.lang.Object obj)
- Overrides:
equals
in classjava.lang.Object
- See Also:
Object.equals(java.lang.Object)
-
getDecorationMap
public java.util.Map<java.lang.String,CmsDecorationObject> getDecorationMap()
Returns the decorationMap.- Returns:
- the decorationMap
-
getLocale
public java.util.Locale getLocale()
Returns the locale.- Returns:
- the locale
-
getName
public java.lang.String getName()
Returns the name.- Returns:
- the name
-
hashCode
public int hashCode()
- Overrides:
hashCode
in classjava.lang.Object
- See Also:
Object.hashCode()
-
setDecorationMap
public void setDecorationMap(java.util.Map<java.lang.String,CmsDecorationObject> decorationMap)
Sets the decorationMap.- Parameters:
decorationMap
- the decorationMap to set
-
toString
public java.lang.String toString()
- Overrides:
toString
in classjava.lang.Object
- See Also:
Object.toString()
-
-