org.pentaho.reporting.engine.classic.core.filter
Class ComponentDrawableFilter

java.lang.Object
  extended by org.pentaho.reporting.engine.classic.core.filter.ComponentDrawableFilter
All Implemented Interfaces:
Serializable, Cloneable, DataFilter, DataSource, DataTarget

public class ComponentDrawableFilter
extends Object
implements DataFilter

A filter that wraps AWT- and Swing-components into a Drawable implementation.

Author:
Thomas Morgner
See Also:
Serialized Form

Constructor Summary
ComponentDrawableFilter()
          Default constructor.
 
Method Summary
 Object clone()
          Creates a clone of this filter.
 DataSource getDataSource()
          Returns the assigned DataSource for this Target.
 Object getValue(ExpressionRuntime runtime, Element element)
          Returns the ComponentDrawable for the AWT-Component or null.
 void setDataSource(DataSource ds)
          Assigns a DataSource for this Target.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ComponentDrawableFilter

public ComponentDrawableFilter()
Default constructor.

Method Detail

getValue

public Object getValue(ExpressionRuntime runtime,
                       Element element)
Returns the ComponentDrawable for the AWT-Component or null.

Specified by:
getValue in interface DataSource
Parameters:
runtime - the expression runtime that is used to evaluate formulas and expressions when computing the value of this filter.
element -
Returns:
the value.

clone

public Object clone()
             throws CloneNotSupportedException
Creates a clone of this filter.

Specified by:
clone in interface DataSource
Specified by:
clone in interface DataTarget
Overrides:
clone in class Object
Returns:
the clone.
Throws:
CloneNotSupportedException - if an error occured.

getDataSource

public DataSource getDataSource()
Returns the assigned DataSource for this Target.

Specified by:
getDataSource in interface DataTarget
Returns:
The datasource.

setDataSource

public void setDataSource(DataSource ds)
Assigns a DataSource for this Target.

Specified by:
setDataSource in interface DataTarget
Parameters:
ds - The data source.