com.opencms.template.cache
Class CmsElementDescriptor

java.lang.Object
  |
  +--com.opencms.template.cache.CmsElementDescriptor

public class CmsElementDescriptor
extends Object

This descriptor is used to locate CmsElement-Objects with the CmsElementLocator. It is the key for a CmsElement.

Author:
Andreas Schouten

Constructor Summary
CmsElementDescriptor(String className, String templateName)
          The constructor to create a new CmsElementDescriptor.
 
Method Summary
 boolean equals(Object obj)
          Compares the overgiven object with this object.
 String getClassName()
          Get the class name for the element defined.
 String getKey()
          Returns the key of this descriptor.
 String getTemplateName()
          Get the template name for the element defined.
 int hashCode()
          We have to return a hashcode for the hashtable.
 String toString()
          toString methode
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

CmsElementDescriptor

public CmsElementDescriptor(String className,
                            String templateName)
The constructor to create a new CmsElementDescriptor.

Parameters:
className - the name of the class for this descriptor.
templateName - the name of the template for this descriptor.
Method Detail

getKey

public String getKey()
Returns the key of this descriptor.

Returns:
the key of this descriptor.

getClassName

public String getClassName()
Get the class name for the element defined.

Returns:
Class name for the element.

getTemplateName

public String getTemplateName()
Get the template name for the element defined.

Returns:
Template name for the element.

hashCode

public int hashCode()
We have to return a hashcode for the hashtable. We can use the hashcode from the Strings m_className and m_templatename.

Overrides:
hashCode in class Object
Returns:
The hashCode.

equals

public boolean equals(Object obj)
Compares the overgiven object with this object.

Overrides:
equals in class Object
Returns:
true, if the object is identically else it returns false.

toString

public String toString()
toString methode

Overrides:
toString in class Object