| java.lang.Object org.jfree.report.TableDataFactory
TableDataFactory | public class TableDataFactory implements DataFactory,Cloneable,Serializable(Code) | | The TableDataFactory provides keyed access to predefined tablemodels. The factory does not accept parameters and
therefore cannot be used for parametrized queries. The queryname is used to lookup the table by its previously
registered name.
author: Thomas Morgner |
Method Summary | |
public void | addTable(String name, TableModel tableModel) Registers a tablemodel with the given name. | public Object | clone() Creates a copy of this data-factory. | public void | close() Closes the data factory. | public DataFactory | derive() Derives a freshly initialized report data factory, which is independend of the original data factory. | public void | open() This does nothing. | public TableModel | queryData(String query, DataRow parameters) Queries a datasource. | public void | removeTable(String name) Removes the table that has been registered by the given name. |
TableDataFactory | public TableDataFactory()(Code) | | Default Constructor.
|
TableDataFactory | public TableDataFactory(String name, TableModel tableModel)(Code) | | Creates a new TableDataFactory and registers the tablemodel with the given name.
Parameters: name - the name of the table. Parameters: tableModel - the tablemodel. |
addTable | public void addTable(String name, TableModel tableModel)(Code) | | Registers a tablemodel with the given name. If a different tablemodel has been previously registered with the same
name, this table will replace the existing one.
Parameters: name - the name of the table. Parameters: tableModel - the tablemodel that should be registered. |
close | public void close()(Code) | | Closes the data factory. Actually, this one does nothing at all.
|
open | public void open()(Code) | | This does nothing.
|
queryData | public TableModel queryData(String query, DataRow parameters)(Code) | | Queries a datasource. The string 'query' defines the name of the query. The Parameterset given here may contain
more data than actually needed.
The dataset may change between two calls, do not assume anything!
Parameters: query - the name of the table. Parameters: parameters - are ignored for this factory. the report data or null. |
removeTable | public void removeTable(String name)(Code) | | Removes the table that has been registered by the given name.
Parameters: name - the name of the table to be removed. |
|
|