Class ElementStyleSheetObjectDescription
- java.lang.Object
-
- org.pentaho.reporting.engine.classic.core.modules.parser.ext.readhandlers.ElementStyleSheetObjectDescription
-
- All Implemented Interfaces:
Serializable
,ObjectDescription
public class ElementStyleSheetObjectDescription extends Object implements ObjectDescription
Creation-Date: Dec 17, 2006, 2:36:55 PM- Author:
- Thomas Morgner
- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description ElementStyleSheetObjectDescription()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
configure(org.pentaho.reporting.libraries.base.config.Configuration config)
Configures this factory.Object
createObject()
Creates an object based on the description.ObjectDescription
getInstance()
Returns a cloned instance of the object description.Class
getObjectClass()
Returns the object class.Object
getParameter(String name)
Returns the value of a parameter.Class
getParameterDefinition(String name)
Returns a parameter definition.Iterator
getParameterNames()
Returns an iterator the provides access to the parameter names.ObjectDescription
getUnconfiguredInstance()
Returns a cloned instance of the object description.void
init(org.pentaho.reporting.libraries.xmlns.parser.RootXmlReadHandler rootHandler, ElementStyleSheet styleSheet)
void
setParameter(String name, Object value)
Sets the value of a parameter.void
setParameterFromObject(Object o)
Sets the parameters of this description object to match the supplied object.-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.pentaho.reporting.engine.classic.core.modules.parser.ext.factory.base.ObjectDescription
equals, hashCode
-
-
-
-
Method Detail
-
configure
public void configure(org.pentaho.reporting.libraries.base.config.Configuration config)
Configures this factory. The configuration contains several keys and their defined values. The given reference to the configuration object will remain valid until the report parsing or writing ends. The configuration contents may change during the reporting.- Specified by:
configure
in interfaceObjectDescription
- Parameters:
config
- the configuration, never null
-
init
public void init(org.pentaho.reporting.libraries.xmlns.parser.RootXmlReadHandler rootHandler, ElementStyleSheet styleSheet)
-
createObject
public Object createObject()
Creates an object based on the description.- Specified by:
createObject
in interfaceObjectDescription
- Returns:
- The object.
-
getInstance
public ObjectDescription getInstance()
Returns a cloned instance of the object description. The contents of the parameter objects collection are cloned too, so that any already defined parameter value is copied to the new instance. Parameter definitions are not cloned, as they are considered read-only.- Specified by:
getInstance
in interfaceObjectDescription
- Returns:
- A cloned instance.
-
getObjectClass
public Class getObjectClass()
Returns the object class.- Specified by:
getObjectClass
in interfaceObjectDescription
- Returns:
- The Class.
-
getParameter
public Object getParameter(String name)
Returns the value of a parameter.- Specified by:
getParameter
in interfaceObjectDescription
- Parameters:
name
- the parameter name.- Returns:
- The value.
-
getParameterDefinition
public Class getParameterDefinition(String name)
Returns a parameter definition. If the parameter is invalid, this function returns null.- Specified by:
getParameterDefinition
in interfaceObjectDescription
- Parameters:
name
- the definition name.- Returns:
- The parameter class or null, if the parameter is not defined.
-
getParameterNames
public Iterator getParameterNames()
Returns an iterator the provides access to the parameter names. This returns all _known_ parameter names, the object description may accept additional parameters.- Specified by:
getParameterNames
in interfaceObjectDescription
- Returns:
- The iterator.
-
getUnconfiguredInstance
public ObjectDescription getUnconfiguredInstance()
Returns a cloned instance of the object description. The contents of the parameter objects collection are cloned too, so that any already defined parameter value is copied to the new instance. Parameter definitions are not cloned, as they are considered read-only. The newly instantiated object description is not configured. If it need to be configured, then you have to call configure on it.- Specified by:
getUnconfiguredInstance
in interfaceObjectDescription
- Returns:
- A cloned instance.
-
setParameter
public void setParameter(String name, Object value)
Sets the value of a parameter.- Specified by:
setParameter
in interfaceObjectDescription
- Parameters:
name
- the parameter name.value
- the parameter value.
-
setParameterFromObject
public void setParameterFromObject(Object o) throws ObjectFactoryException
Sets the parameters of this description object to match the supplied object.- Specified by:
setParameterFromObject
in interfaceObjectDescription
- Parameters:
o
- the object.- Throws:
ObjectFactoryException
- if there is a problem while reading the properties of the given object.
-
-